compiling in visaul c++

Light Poster
6Mar2010,16:45   #1
lipun4u's Avatar
I m newly using visual microsoft c++ 2008. I want to use stand C++ in this IDE. But when ever I try to compile any code, it gives me some crazy errors which say that I must include stdafx.h.

Please suggest me how to get rid of this.
Skilled contributor
6Mar2010,17:13   #2
techgeek.in's Avatar
I m pretty sure that u have tried to make a "win 32 console Application"... thr "stdafx.h" and "stdafx.cpp" are necessary files... In order to use visual c++ as a normal c++ IDE then navigate to:
File---->New. There in the "files" tab select the "C++ source file". Now, I hope u wnt be getting any "stdafx.h" related errors..
Mentor
8Mar2010,04:10   #3
xpi0t0s's Avatar
stdafx.h is only required if you have specified "Use precompiled headers". If you don't want to include stdafx.h, uncheck that option. Project - Settings - C/C++, you'll find it somewhere under there.