-
Passing a File Handle...
I tried this:
void a_function(FILE *inFile);
int main()
{
FILE *inFile;
a_function(inFile);
}
void a_function(File *inHandle)
{
File *inHandle;
}
...but no good!
What I want to know is can it be done. Can a file handle be passed around like a drunk girl at a frat party?
-
Well it might work, if
- you opened the file before passing the handle to the function
- you noticed that FILE is not the same as File (case matters)
Oh, and please note the post at the top of the forum for guidelines on posting code.
-