Thread: getline()
View Single Post
Old 08-29-2005, 05:35 PM   #1 (permalink)
bradleyc
Registered User
 
Join Date: Aug 2005
Posts: 17
bradleyc is on a distinguished road
getline()

With a getline ... can you do something like ...eof?

Code:
long videoNum; char videoName[1];

cout << "  -- Current Record --    " << endl;
cout << "  What is the Video Number?: ";
cin.getline (videoNum, EOF);
cout << "  What is the Video Name?: ";
cin.getline (videoName, EOF);



cout << "  -- New Record --    " << endl;
cout << "  What is the Video Number?: ";
cin >> videoNum2;
cout << "  What is the Video Name?: ";
cin >> videoName2;
Than how would i replace the videoNum with videoNum2? videoName with videoName2?
bradleyc is offline   Reply With Quote