I'm trying to pass an HBITMAP to a function which is suppose to put the HBITMAP on a static control. But it doesnt work :-\
this doesnt work, but if i send the message from the Windows Procedure (which is where i load the bitmap, in the WM_CREATE message) it works just fine.Code:
void SetImage(HBITMAP bitmap)
//hwnd is the handle to the static control
SendMessage(hwnd, STM_SETIMAGE, IMAGE_BITMAP, bitmap);
What am i doing wrong?