如题,按钮通过create成员函数动态创建.

解决方案 »

  1.   

    wParam 
    The low-order word of wParam identifies the command ID of the menu item, control, or accelerator. The high-order word of wParam specifies the notification message if the message is from a control. If the message is from an accelerator, the high-order word is 1. If the message is from a menu, the high-order word is 0. lParam 
    Identifies the control that sends the message if the message is from a control. Otherwise, lParam is 0. 
      

  2.   

    在容器窗口的OnCommand消息中
    nNotifyCode = HIWORD(wParam);
    nControlID = LOWORD(wParam);
      

  3.   

    在容器窗口的OnCommand消息中
    nNotifyCode = HIWORD(wParam);  //通知代码 = 0
    nControlID = LOWORD(wParam);   //控件id  你的按钮id
    if(nNotifyCode == 0 && nControlID ==你的按钮id)
    {
      //你的按钮被按下
    }
      

  4.   

    spwnihao(╭∩╮(︶⌒︶)╭∩╮鄙视一切),谢谢,那按钮放开的通知码是多少呢?