菜鸟问题。
下面这段程序是从教程上copy的,
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <windowsx.h>
int WINAPI WinMain(HINSTANCE hinstance,HINSTANCE hprevinstance,LPSTR lpcmdline,int ncmdshow)
{
MessageBox(NULL,"THERE CAN BE ONLY ONE!!!","MY FIRST WINDOWS PROGRAM",MB_OK|MB_ICONEXCLAMATION);
return(0);
}
为什么在VC下编译提示出错,
--------------------Configuration: test - Win32 Debug--------------------
Linking...
LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
Debug/test.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.