Advertisement

Learning the window api

Started by September 26, 2001 07:57 PM
1 comment, last by Nothingness 23 years, 2 months ago
Well I just got the book "tricks of the windows game programming gurus" i just pretty much made the program with the message box appears. But 2 errors come up. They say unresolved external symbol _main 1 unresolved externals
      
#include <windows.h>

#include <windowsx.h>


int WINAPI WinMain(HINSTANCE hinstance,HINSTANCE hprevinstance,
                   LPSTR lpcmdline,int ncmdshow)

{


//message box

MessageBox(NULL,"HELLO","MESSAGE BOX", MB_OK | MB_ICONEXCLAMATION);

//exit program

 return 0;
}
      
This is the code by the way. I hope you can help. I dont want all my programs to have these errors. Edited by - Nothingness on September 26, 2001 8:59:07 PM Edited by - Nothingness on September 26, 2001 8:59:22 PM
Make sure that your project is a Win32 app, not a Win32 console app.

~~~~~~~~~~
Martee
ReactOS - an Open-source operating system compatible with Windows NT apps and drivers
Advertisement
Ok that worked. Thanks!!!

This topic is closed to new replies.

Advertisement