vc写最简单的windows图形界面程序提示出错,No such file or directory执行
// text123.cpp : Defines the entry point for the application.//
#include "stdafx.h"
int APIENTRY WinMain(HINSTANCE hInstance,
HINSTANCE hPrevInstance,
LPSTR lpCmdLine,
int nCmdShow)
{
// TODO: Place code here.
MessageBox(NULL,TEXT("hello"),TEXT("hi"),MB_OK);
return 0;
}
上边是源程序
fatal error C1083: Cannot open precompiled header file: 'Debug/text123.pch': No such file or directory
执行 cl.exe 时出错.
text123.obj - 1 error(s), 0 warning(s)
这个是提示的错误,求解释
另外本人系统为w8.1,但已成功解决兼容性问题
头文件路径不对, #include<windows.h>才是正确的头文件 # include <windows.h>
页:
[1]