请教:在 win32 application 工程里,为什么 AfxMessageBox("123"); 编译时有错误呢?谢谢!
请教:
在 win32 application 工程里,
为什么 AfxMessageBox( "123 ");
编译时有错误呢?
#include "stdafx.h "
#include "resource.h "
#include "windows.h "
--------------------Configuration: ini测试6 - Win32 Debug--------------------
Compiling...
ini测试6.cpp
C:\initest6\ini测试6.cpp(182) : error C2065: 'AfxMessageBox ' : undeclared identifier
Error executing cl.exe.
ini测试6.exe - 1 error(s), 0 warning(s)
我是错在哪里?需要怎么改?
谢谢!
[解决办法]
AfxMessageBox依赖于MFC
所以使用
MessageBox吧
[解决办法]
加上Afxwin.h
头文件看看
[解决办法]
加上Afxwin.h可能还会出现其他错误,所以还是用MessageBox比较好