Archived

This topic is now archived and is closed to further replies.

kenobey

Help please!!

Recommended Posts

I have i errorfile.cpp that looks like this: #include "errorfile.h" ofstream wfile; void WriteErrorFile(char *filename, char *error) { ofstream wfile; wfile.open(filename); wfile << error; wfile << flush; wfile.close(); return(1); } int ReadErrorFile(char *filename) { return(1); } /////////////// and a errorfile.h that looks like this: #ifndef ErrorFile #define ErrorFile #include extern void WriteErrorFile(char *filename, char *error); extern int ReadErrorFile(char *filename); #endif ///////////////// but i can''t use it, "fatal error C1010: unexpected end of file while looking for precompiled header directive" What am I doing wrong?

Share this post


Link to post
Share on other sites
This sounds to me like you use VC6 and have enabled precompiled headers, created a new .cpp file and forgot to include "stdafx.h" to your new .cpp file. Or you disable precompiled headers in the project options.

The last truth is that there is no magic(Feist)

Share this post


Link to post
Share on other sites