EventMenu()

Syntax

MenuItem = EventMenu()
Description
After an event of type #PB_Event_Menu (returned by WindowEvent() or WaitWindowEvent()), use this function to determine which menu item, toolbar item or keyboard shortcut has been selected.

Parameters

None.

Return value

Returns the menu item, toolbar item or keyboard shortcut number associated to the event.

Remarks

A toolbar event is like a menu event (as toolbars are shortcuts for menu items most of the time). So it's a good idea, if the toolbar buttons and the menu items have the same ID, then the same operation can be done on both without any additional code.

See Also

WindowEvent(), WaitWindowEvent()

Supported OS

All

<- EventGadget() - Window Index - EventTimer() ->