Hi, I'm trying to get this to compile correctly, but I'm having an error. I'm basically just creating a window, registering it, and displaying it to the screen :
The italicized line is where the compiler is indicating a problem. It says I'm doing an "invalid conversion from void* to HBRUSH__*". Now I've tried casting the so-called line with HBRUSH,HBRUSH*, HBRUSH__* and so on, but no dice. Any ideas ?Code:WNDCLASS winclass; // this will hold the class created HWND hwnd; // generic window handle MSG msg; // generic message // window class stucture winclass.style = CS_DBLCLKS | CS_OWNDC | CS_HREDRAW | CS_VREDRAW; winclass.lpfnWndProc = WindowProc; winclass.cbClsExtra = 0; winclass.cbWndExtra = 0; winclass.hInstance = hinstance; winclass.hIcon = LoadIcon(NULL, IDI_APPLICATION); winclass.hCursor = LoadCursor(NULL, IDC_ARROW); winclass.hbrBackground = GetStockObject(BLACK_BRUSH); winclass.lpszMenuName = NULL; winclass.lpszClassName = WINDOW_CLASS_NAME;
I'm using Dev-C++. I don't know whether or not that's an issue.