The HiliteMenuItem function highlights or removes the highlighting from an item in a menu bar.
BOOL HiliteMenuItem(
HWND hwnd, |
// handle to the window with the menu |
HMENU hmenu, |
// handle to the menu |
UINT uItemHilite, |
// menu item to highlight or unhighlight |
UINT uHilite |
// highlight flags |
); |
Value |
Meaning |
MF_BYCOMMAND |
Indicates that uItemHilite gives the identifier of the menu item. |
MF_BYPOSITION |
Indicates that uItemHilite gives the zero-based relative position of the menu item. |
MF_HILITE |
Highlights the menu item. If this flag is not specified, the highlighting is removed from the item. |
MF_UNHILITE |
Removes highlighting from the menu item. |
If the menu item is set to the specified highlight state, the return value is nonzero.
If the menu item is not set to the specified highlight state, the return value is zero.
The MF_HILITE and MF_UNHILITE flags can be used only with the HiliteMenuItem function; they cannot be used with the ModifyMenu function.
See: