Cpp files in a MFC project have to include "stdafx.h" for creating precompiled headers.
Solution:
#include "stdafx.h" or turn off using precompiled headers.
Visual Studio 2003 .NET
[Properties] of that *.cpp file -> [C/C++] -> [Precompiled Headers]
Set [Create/Use Precompiled Header] to "Not Using Precompiled Headers"