As far as I know files can only have one EOF and it is put there automatically, you can't do it at will. You can design your code to stop writing to file or reading from file at will, that is at a given flag, which could be any valid symbol or group of symbols.

for example, say you never will have a tilde in the useable data contained in a file. Then you can use a tilde to act as a flag.
Code:
ofstream fout("filename.ext");

char data[] = "Save up to the tilde. ~ Not after.";

for(int i = 0; i < strlen(data); ++i)
{
  if(data[i] != '~')
    fout << data[i];
}
and the reverse if you have created a file in some other program and want to read it in to the current program up to a given flag.

Code:
ifstream fin("filename.ext")

char input[100];
char ch;
int index = 0;

fin >> ch;
while(ch != '~' && fin)
{
   input[index++] = ch;
   fin >> ch;
}
input[index] = '\0';
there are other ways of accomplishing this using different types of flags, etc. , but this works. To my knowledge, however, you can not have more than one EOF per file and you can't manipulate where it is.