VS .NET 2003 Strange compiler error

Fresh new Win32(not console) project.

Replaced CreateWindow with CreateWindowEx

BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)

{

HWND hWnd;



hInst = hInstance; // Store instance handle in our global variable



hWnd = CreateWindowEx(WS_EX_LAYERED, szWindowClass, szTitle, WS_OVERLAPPEDWINDOW,

CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, NULL, NULL, hInstance, NULL);



if (!hWnd)

{

return FALSE;

}



ShowWindow(hWnd, nCmdShow);

UpdateWindow(hWnd);



return TRUE;

}

windows.h and winuser.h are included, but it keeps telling me that WS_EX_LAYERED is undefined identifier. :dumbass:

#331728

You'll need to set your windows version before including windows.h

Something like

#define _WIN32_WINNT 0x500 // w2k at least

#define WINVER 0x0500 // w2k at least

#331730

Oh thanks :) MSDN is quite short-spoken on this point :)

#331732

::Off topic:: but is your avatar you as squall from FF8?

#331825

That is most definitely NOT Squall.

Rant>

#331976

That is most definitely NOT Squall.

Rant>

I said HIM as squall, have a poster of squall in a similar position, and there is a striking resembelance, but whetever, I dont' care that much to argue.

#332029