-
visual c++ error
hi,
when i try building my code with visual c++ 2005 Express Edition..
the compiler gives the error..
fatal error C1010: unexpected end of file while looking for precompiled header. Did you forget to add '#include "stdafx.h"' to your source?
but when i use cygwin (g++) it compiles and runs fine...can someone tell me how i can fix this error...
btw...when i do inlcude the suggested file ...it gives a new error
fatal error C1083: Cannot open precompiled header file: 'Debug\inheritance.pch': No such file or directory
Square.cpp
thanks.
-
look in project options and turn off precompiled headers
-
after you include that file, delete everything in the debug folder of your project, if you still get the debug error when you compile again, post the error message
-
You don't need precompiled headers for a simple, portable program. Turn them off instead of including the file. When you create your project, make sure you create a blank solution instead of a Win32 Console Application. I believe the blank solution starts out with precompiled headers turned off, although I don't have the 2005 version to be sure.