Wednesday, 28 August 2013

c++ variable declaration syntax

c++ variable declaration syntax

When I take something as simple as this:
char text1 = "hello world";
MessageBox(NULL, text1, NULL, NULL);
I get those Errors:
Error 1 error C2440: 'initializing' : cannot convert from 'const char
[12]' to 'char'
Error 2 error C2664: 'MessageBoxW' : cannot convert parameter 2 from
'char' to 'LPCWSTR'

No comments:

Post a Comment