Jump to content

WM MENUSELECT

From EDM2

This message occurs when a menu item has been selected.

Syntax

param1
    USHORT usItem;        /* Identifier of selected item. */
    USHORT usPostCommand; /* Post-command flag. */

param2
    HWND   hwnd;         /* Menu-control window handle. */

Parameters

usItem (USHORT) - input
Identifier of selected item.
usPostCommand (USHORT) - input
Post-command flag.
TRUE: Indicates that either a WM_COMMAND, WM_SYSCOMMAND, or WM_HELP message is being posted by the menu control on return from the owner, subject to rc.
FALSE: Indicates that no message is being posted by the menu control on return from the owner, subject to rc.
hwnd (HWND) - input
Menu-control window handle.

Returns

rc (BOOL) - returns
Post indicator.
TRUE: Indicates that either a WM_COMMAND, WM_SYSCOMMAND, or WM_HELP message is to be posted by the menu control window procedure. The menu is dismissed if the selected item does not have a style of MIA_NODISMISS.
FALSE: Indicates that no message is to be posted by the menu control window procedure and that the menu is not dismissed.

Remarks

in Frame Controls

The identity of the top-level action-bar menu that generated this message is found. If the identity is FID_MENU, the message is passed to the window with identity FID_CLIENT.

in Menu Controls

The menu control window procedure generates this message and sends it to its owner, informing the owner of this event.

When the message is returned from its owner, menu control acts on rc as appropriate.

It must not be posted to the menu control.

Default Processing

The default window procedure takes no action on this message, other than to set rc to TRUE.

Related Messages

  • WM_MENUSELECT (in Frame Controls)
  • WM_MENUSELECT (in Menu Controls)