GetItemStatefunction
Retrieves the state of the specified menu item.
No implementation located. This member is documented, but the source scan found no matching declaration. It is likely declared in a header this scan does not resolve, or provided by a macro.
Syntax
FUNCTION GetItemState (BYVAL hMenu AS HMENU, BYVAL uItem AS DWORD, BYVAL fByPosition AS LONG = FALSE) AS DWORD
Parameters
| Name | Description | |
|---|---|---|
hMenu | Handle to the menu that contains the menu item. | |
uItem | The identifier or position of the menu item to get information about. The meaning of this parameter depends on the value of fByPosition. | |
fByPosition | The meaning of uItem. If this parameter is FALSE, uItem is a menu item identifier. Otherwise, it is a menu item position. |
Return value
0 on failure or one or more of the following values:
Description
Retrieves the state of the specified menu item.
Examples
MFS_CHECKED The item is checked MFS_DEFAULT The menu item is the default. MFS_DISABLED The item is disabled. MFS_ENABLED The item is enabled. MFS_GRAYED The item is grayed. MFS_HILITE The item is highlighted MFS_UNCHECKED The item is unchecked. MFS_UNHILITE The item is not highlighted.
DIM dwState AS DWORD = CMenu.GetItemState(hMenu, IDM_OPEN)
Reference
- Documented in Windows/WIndows Controls/CMenu Class.md
- Topic: About Menus