What would be the purpose of putting a pause at the end of your menu? Is the a portion of a code intended for a loop?
Type: Posts; User: Ana Val sazi
What would be the purpose of putting a pause at the end of your menu? Is the a portion of a code intended for a loop?
You need to declare common;
ie
char common[20];
...before you can use it effectively.
I recently switched all gets to cin.getline
fflush (stdin);
cin.getline(video_title,30,'\n');
THanks for the help you all are providing. Ive tinkered around with both blight2c's and hammer's idea and this is what I came up with;
strcpy(inventory[deleteNum].title," ");
This will...
int main()
{
int numMovies; // initialize variable to designate a record in the array
Video inventory[100]; // This is the array of videos
char...
I can delete the record in the memory, I can not delete the record in the file. In fact with the suggestive code displayed on this page
I'm getting some funny characters in my text file as well as on my screen.
Iv'e noticed that it dosen't even write any info until after the alloted space...and I'm not even using all of the space. ...
Do You mean I should write it like this;
inventory[deleteNum].title ==inventory[numMovies-1].title)
and place it after the for loop is completed? (Because, If I understand my own writting.......
This may seem like a dumb question, but here goes...
I have been using .txt files whereas I see others using .dat or something else. I usually end up opening .dat file with notebook. Does my...
I have a delete function that will delete the specified record. In turn it will take the last record and place it in the the deleted spot. However it does not erase the record at the end, causing a...
May I should have clarified a couple of things.:(
Video is a struct containing variables for title, movie star, etc...
Here, I guess I'll just post a the first portion of my main...
...
Thanks for your help as well as bringing a couple of things to my attention.
The cin.get advice was helpful but did not solve my dilema in the extra machine language being outputed to the fstream...
I am a little mifted in my add and delete functions. This program is suppose to add and delete video titles and their info from the database/file. The program allows me to "add", but it somehow...
Perhaps if you somethin like this for input:
infile.get(array[num].star,##);
and for output:
infile << strupr(array[num].member) << endl;
if you want to print your information,...