Button_GetState macro (windowsx.h)
Retrieves the state of a button or check box. You can use this macro or send the BM_GETSTATE message explicitly.
Syntax
LRESULT Button_GetState(
HWND hwndCtl
);
Parameters
hwndCtl
Type: HWND
A handle to the button control.
Return value
Type: LRESULT
The return value specifies the current state of the button. It is a combination of the following values:
Return code | Description |
---|---|
BST_CHECKED | The button is checked. |
BST_DROPDOWNPUSHED | Windows Vista. The button is in the drop-down state. Applies only if the button has the TBSTYLE_DROPDOWN style. |
BST_FOCUS | The button has the keyboard focus. |
BST_HOT | The button is hot; that is, the mouse is hovering over it. |
BST_INDETERMINATE | The state of the button is indeterminate. Applies only if the button has the BS_3STATE or BS_AUTO3STATE style. |
BST_PUSHED | The button is being shown in the pushed state. |
BST_UNCHECKED | No special state. Equivalent to zero. |
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | windowsx.h |
See also
Reference