I wrote the below code & it worked to retrieve a string from a file.
Two variables to fine tune what to capture after finding the required starting & ending string
int lnstarts, int leadingln
My question is how to perform the below line with something like below?
int line1=line+1
str=line1.substr(pos1+lnstarts, pos2-pos1-lnstarts);
I know line is a string type but just for the question I am using it to ask how to go to next line to capture.
The string in current line & next line is almost same.
Is there a way to go to next line from current line position?
halla
to capture every thing in a line ,yo need to include '\n' when capturing tha string
see what i mean
1 2 3 4 5 6 7 8 9
cout<<"entre film name :";
getline(cin,filmname,'\n');
cout<<"enter your lovely book :";
getline(cin,book,'\n');
cout<<" your film name is "<<filmname<<endl;
cout<<"your lovely book is "<<book<<endl;
try to show that each time you capture information indipendly