VC中如何得到是谁发出了BN_CLICKED 消息?
当单击按钮时,产生BN_CLICKED消息,但函数无参数,怎样得到如下帮助所说的:WPARAM wParam
LPARAM lParam;我关键是想得到谁发出了这个消息(单击哪个):
BN_CLICKED Notification
--------------------------------------------------------------------------------
The BN_CLICKED notification code is sent when the user clicks a button.
The parent window of the button receives the BN_CLICKED notification code through the WM_COMMAND message.
Syntax
BN_CLICKED
WPARAM wParam
LPARAM lParam;
Parameters
wParam
The low-order word contains the button's control identifier. The high-order word specifies the notification message.
lParam
Handle to the button.
Return Value
No return value.
Remarks
A disabled button does not send a BN_CLICKED notification message to its parent window.
Notification Requirements
Minimum DLL Version None
Header Declared in Winuser.h, include Windows.h
Minimum operating systems Windows 95, Windows NT 3.1