hello,
I'm reading Beginning Game Programming (Jonathan S. Harbour), when i want to compile simple HelloWorld Application :
#include<windows.h>
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
LPSTR lpCmdLine, int nCmdShow)
{
MessageBox(NULL, "All your base are belong to us!",
"Hello World", MB_OK | MB_ICONEXCLAMATION);
}
Visual C++ ( Visual Studio 2005 ) show me this output :
1>------ Build started: Project: 001_HelloWorld, Configuration: Debug Win32 ------
1>Compiling...
1>main.cpp
1>c:\documents and settings\toshiba\my documents\visual studio 2005\projects\001_helloworld\001_helloworld\main.cpp(10) : error C2664: 'MessageBoxW' : cannot convert parameter 2 from 'const char [32]' to 'LPCWSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>Build log was saved at "file://c:\Documents and Settings\TOSHIBA\My Documents\Visual Studio 2005\Projects\001_HelloWorld\001_HelloWorld\Debug\BuildLog.htm"
1>001_HelloWorld - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
and stop compile what's the problem and how to solve it ?
if the is any good books for create Win32 Application please post the name of the book
thanks in advance...
Regards,
SB4