WM_MDISETMENU

This message replaces the menu of a multiple document interface (MDI) frame window, the Window pop-up menu, or both.

Parameters

wParam

Contains in the menu handle (HMENU) of the new frame-window menu. If wParam is zero, the frame-window menu is not changed.

lParam

Contains the menu handle (HMENU) of the new Window pop-up menu. If lParam is zero, the pop-up menu is not changed.

Return Value

The return value is the handle of the frame-window menu replaced by this message.

Comments

After sending this message, an application must call the DrawMenuBar function to update the menu bar.

If this message replaces the Window pop-up menu, MDI child-window menu items are removed from the previous Window menu and added to the new Window pop-up menu.

If an MDI child window is maximized and this message replaces the MDI frame-window menu, the System menu and restore controls are removed from the previous frame-window menu and added to the new menu.

See Also

DrawMenuBar