I saw the post, this is my definition prototype
void getInput(contact *, ifstream);
Now you are saying I should use
void getInput(contact *myContacts, ifstream);
But what if I do not wish to put a variable name there?
void getInput(contact *myContacts, ifstream fin)
the first argument should probably be
contact &myContacts in C++ - try to avoid using pointers if you can use a reference.
Secondly ifstream should be passed by reference. these objects (the i/o streams) do not copy well (I have crashed many a program over trying to pass cin/cout by value -- and it takes FOREVER to figure out what is wrong).
void getInput(contact &myContacts, ifstream &fin)
Edit well -- at least pass fin by reference...
Ok wil be sure to pass fin by reference