BM_CLICK

An application sends a BM_CLICK message to simulate the user clicking a button. This message causes the button to receive a WM_LBUTTONDOWN and a WM_LBUTTONUP message, and the button's parent window to receive a BN_CLICKED notification message.

BM_CLICK 
wParam = 0;     // not used; must be zero 
lParam = 0;     // not used; must be zero 
 

Parameters

This message has no parameters.

Return Values

This message does not return a value.

Remarks

If the button is in a dialog box and the dialog box is not active, the BM_CLICK message might fail. To ensure success in this situation, call the SetActiveWindow function to activate the dialog box before sending the BM_CLICK message to the button.

QuickInfo

  Windows NT: Requires version 3.5 or later.
  Windows: Requires Windows 95 or later.
  Windows CE: Requires version 1.0 or later.
  Header: Declared in winuser.h.

See Also

Buttons Overview, Button Messages, BN_CLICKED, SetActiveWindow, WM_LBUTTONDOWN, WM_LBUTTONUP