fatal error C1189: #error : WINDOWS.H already included. MFC apps must not #include <windows.h>

问题:
win32工程里在main.cpp里包含头文件afxwin.h,后报错:
vc2010下多线程程序报错“fatal error C1189: #error : WINDOWS.H already included. MFC apps must not #include <windows.h>”

原因:
afxwin.h头文件包含位置问题,将afxwin.h包含语句移动到stdafx.h里后,OK.

猜你喜欢

转载自blog.csdn.net/qq_43248127/article/details/113979119
今日推荐