如何判断对话框上的Edit的控件是否,发生了改变!
我在对话框上,放了Edit,Buttion和Commbox控件,我如何判断用户是否改变里的其上的值啊!

解决方案 »

  1.   

    处理EN_CHANGE消息--------------------------------------------------------------------------------The EN_CHANGE notification message is sent when the user has taken an action that may have altered text in an edit control. Unlike the EN_UPDATE notification message, this notification message is sent after the system updates the screen. The parent window of the edit control receives this notification message through a WM_COMMAND message. SyntaxEN_CHANGE    WPARAM wParam
        LPARAM lParam;
    ParameterswParam
    The low-order word specifies the edit control identifier. 
    The high-order word specifies the notification message. lParam
    Handle to the edit control. 
    Return ValueNo return value.
    ResRich Edit: Supported in Microsoft Rich Edit 1.0 and later. To receive EN_CHANGE notifications, specify ENM_CHANGE in the mask sent with the EM_SETEVENTMASK message. For information about the compatibility of rich edit versions with the various system versions, see About Rich Edit Controls. The EN_CHANGE notification is not sent when the ES_MULTILINE style is used and the text is sent through WM_SETTEXT. Notification RequirementsMinimum DLL Version None 
    Header Declared in Winuser.h, include Windows.h 
    Minimum operating systems Windows 95, Windows NT 3.1 See AlsoEdit Controls Overview, EN_UPDATE, WM_COMMAND
      

  2.   

    Edit      EN_Change消息
    Combobox  Selchange消息
      

  3.   

    EN_UPDATE Notification--------------------------------------------------------------------------------The EN_UPDATE notification message is sent when an edit control is about to redraw itself. This notification message is sent after the control has formatted the text, but before it displays the text. This makes it possible to resize the edit control window, if necessary. The parent window of the edit control receives this notification message through a WM_COMMAND message. SyntaxEN_UPDATE    WPARAM wParam
        LPARAM lParam;
    ParameterswParam
    The low-order word specifies the edit control identifier. 
    The high-order word specifies the notification message. lParam
    Handle to the edit control. 
      

  4.   

    void CXXXXDlg::OnChangeXXXX()
    {
    ................//
    }