跟VC6不同的地方是消息响应函数的返回值必须为LRESULT
public:
afx_msg LRESULT OnButtonChanged(WPARAM wparam,LPARAM lparam);
LRESULT RFMSStepFlowButton::OnButtonChanged(WPARAM wparam,LPARAM lparam)
{
return NULL;
}
BEGIN_MESSAGE_MAP(RFMSStepFlowButton, CButton)
ON_MESSAGE(WM_MY_BUTTONNAMECHANGED,OnButtonChanged)
END_MESSAGE_MAP()
public:
afx_msg LRESULT OnButtonChanged(WPARAM wparam,LPARAM lparam);
LRESULT RFMSStepFlowButton::OnButtonChanged(WPARAM wparam,LPARAM lparam)
{
return NULL;
}
BEGIN_MESSAGE_MAP(RFMSStepFlowButton, CButton)
ON_MESSAGE(WM_MY_BUTTONNAMECHANGED,OnButtonChanged)
END_MESSAGE_MAP()