I'm trying to use command buttons in my window as described by Ken (by the way, great site, Ken!) and I need to know what the WPARAM and LPARAM values represent when clicking on the buttons.
Here's the code:
This returns 302 for Num1(LOWORD(lparam)) for Button1 and 294 for Num1 for Button2, and for Num2 it returns the same number for both of them. Though each time I run the program it returns one number higher than the last (right now I'm on 44). The none of the numbers match the x,y coords or size of the buttons.Code:
//in my message handling procedure
// I create the buttons
CreateWindowEx(0,"Button","Button1",WS_CHILD | WS_VISIBLE | BS_DEFPUSHBUTTON, 245,5,60,30,hwnd,NULL,hInstMain,NULL);
CreateWindowEx(0,"Button","Button2",WS_CHILD | WS_VISIBLE | BS_DEFPUSHBUTTON, 245,150,60,30,hwnd,NULL,hInstMain,NULL);
//the UINT that represents clicking on a button
//some simple debugging stuff to get the return values
int Num1=LOWORD(lparam), Num2=HIWORD(lparam);
char buff1, buff2, cSep=" , ";
Anyone know what they represent? Thanks in advance for you help.