scarypajamas 0 Newbie Poster

In my MFC c++ app, when I try to include afxwin.h into my project, it gives me these errors. Whats the problem with it? Did I misunderstand something?

I'm using vc++ 2005 express if it makes a difference.

[TEX]1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(250) : warning C4793: 'vararg' : causes native code generation for function 'void AfxTrace(LPCTSTR,...)'
1> C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(250) : see declaration of 'AfxTrace'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(642) : warning C4561: '__fastcall' incompatible with the '/clr' option: converting to '__stdcall'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1171) : error C2143: syntax error : missing '}' before 'generic'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1171) : error C2059: syntax error : 'generic'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1178) : error C2143: syntax error : missing ';' before '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1178) : error C2238: unexpected token(s) preceding ';'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1181) : error C2062: type 'int' unexpected
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1189) : error C2059: syntax error : 'public'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1190) : error C2588: '::~CArchiveException' : illegal global destructor
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1190) : error C2575: 'CArchiveException' : only member functions and bases can be virtual
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1190) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1195) : error C2575: 'GetErrorMessage' : only member functions and bases can be virtual
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1196) : error C2059: syntax error : '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1196) : error C2143: syntax error : missing ';' before '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1196) : error C2059: syntax error : '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1205) : error C2143: syntax error : missing '}' before 'generic'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1205) : error C2059: syntax error : 'generic'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1219) : error C2143: syntax error : missing ';' before '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1219) : error C2238: unexpected token(s) preceding ';'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1222) : error C2062: type 'int' unexpected
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1226) : error C2086: 'int m_cause' : redefinition
1> C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1185) : see declaration of 'm_cause'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1228) : error C2086: 'CString m_strFileName' : redefinition
1> C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1186) : see declaration of 'm_strFileName'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1240) : error C2059: syntax error : 'public'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1241) : error C2588: '::~CFileException' : illegal global destructor
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1241) : error C2575: 'CFileException' : only member functions and bases can be virtual
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1241) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1246) : error C2575: 'GetErrorMessage' : only member functions and bases can be virtual
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1246) : error C2572: 'GetErrorMessage' : redefinition of default parameter : parameter 3
1> C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1194) : see declaration of 'GetErrorMessage'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1247) : error C2059: syntax error : '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1247) : error C2143: syntax error : missing ';' before '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1247) : error C2059: syntax error : '}'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1317) : error C2061: syntax error : identifier 'CFileException'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1398) : error C2061: syntax error : identifier 'CFileException'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(81) : error C2511: 'CArchiveException::CArchiveException(int,LPCTSTR)' : overloaded member function not found in 'CArchiveException'
1> C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1165) : see declaration of 'CArchiveException'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(83) : error C2600: 'CArchiveException::~CArchiveException' : cannot define a compiler-generated special member function (must be declared in the class first)
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(86) : error C2511: 'CFileException::CFileException(int,LONG,LPCTSTR)' : overloaded member function not found in 'CFileException'
1> C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.h(1198) : see declaration of 'CFileException'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(88) : error C2600: 'CFileException::~CFileException' : cannot define a compiler-generated special member function (must be declared in the class first)
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(252) : warning C4244: 'return' : conversion from 'const time_t' to 'LONG_PTR', possible loss of data
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(254) : warning C4244: 'return' : conversion from 'const time_t' to 'LONG_PTR', possible loss of data
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(258) : warning C4244: 'return' : conversion from 'const time_t' to 'LONG_PTR', possible loss of data
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afx.inl(262) : warning C4244: 'return' : conversion from 'const time_t' to 'LONG_PTR', possible loss of data
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc/afxwin.h(4551) : error C2061: syntax error : identifier 'CFileException'
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc\afxwin1.inl(1034) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\mfc\afxwin1.inl(1036) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int[/TEX]