MM_SETITEM
Appearance
This message sets the definition of a menu item.
Syntax
param1 USHORT usReserve; /* Reserved value, should be 0. */ USHORT usincludesubmenus; /* Include submenus indicator. */ param2 PMENUITEM pmenuitem; /* Menu-item data structure. */
Parameters
- usReserve (USHORT) - input
- Reserved value, should be 0.
- usincludesubmenus (USHORT) - input
- Include submenus indicator.
- TRUE: If the menu does not have an item with the specified identifier, search
- the submenus and subdialogs of the menu for an item with the specified identifier
- and set its definition.
- FALSE: If the menu does not have an item with the specified identifier, do not
- search the submenus and subdialogs of the menu for an item with the specified
- identifier.
- TRUE: If the menu does not have an item with the specified identifier, search
Returns
- rc (BOOL) - return
- Success indicator.
- TRUE: Successful completion.
- FALSE: Error occurred.
Remarks
The menu control window procedure responds to this message by using the specified structure to update the definition of the identified menu item. The iPosition field of the structure specified by pmenuitem is ignored, as the position of the item cannot be changed by use of this message.
Note: It must be sent, not posted, to the menu control.
Default Processing
The default window procedure does not expect to receive this message and therefore takes no action on it, other than to set rc to the default value of FALSE.