Important: |
---|
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist. |
This function retrieves information about a menu item.
Syntax
BOOL GetMenuItemInfo( HMENU hMenu, UINT uItem, BOOL fByPosition, LPMENUITEMINFO lpmii ); |
Parameters
- hMenu
-
[in] Handle to the menu that contains the menu item.
- uItem
-
[in] The menu item identifier or the menu item position.
- fByPosition
-
[in] Boolean value of TRUE if uItemis set to a menu item position. This parameter is set to FALSE if uItemis set to a menu item identifier.
- lpmii
-
[in, out] Long pointer to a MENUITEMINFOstructure that specifies the information to retrieve and receives information about the menu item. Note that you must set MENUITEMINFO.cbSize to sizeof(MENUITEMINFO) before calling this function.
Return Value
Nonzero indicates success. Zero indicates failure. To get extended error information, call GetLastError.
Remarks
The system provides the check mark bitmap; therefore, the MENUITEMINFOstructure does not contain information about the check mark bitmaps.
Requirements
Header | winuser.h |
Library | Menu.lib |
Windows Embedded CE | Windows CE 1.0 and later |
Windows Mobile | Windows Mobile Version 5.0 and later |