0

i have 1 problem with window procedure(i belive), the child controls have the BS_NOTIFY style, but the click or others(from BS_NOTIFY style) aren't working.. why?

//in button window procedure:
case WM_COMMAND:
            {
                switch(HIWORD(wParam))
                {
                    case BN_CLICKED:
                    {
                        inst->MouseClick();
                        MessageBox(NULL,"hi","hello",MB_OK);
                    }
                    break;
                }
                break;
            }
            break;

//in form window procedure:
case WM_COMMAND:
                {
                    return DefWindowProc(HandleWindow, WM_COMMAND, wParam, lParam);
                }
                break;

what i'm doing wrong?

0

in form WM_COMMAND message i must do:

SendMessage((HWND)lParam , WM_COMMAND, wParam, lParam);

and now works fine ;)
thanks
readers: if some message don't works, see how you did the Message Loop.. yes i by experience, i lose some keys... but change for the normal Message Loop, works fine ;)

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.