Adds a menu item at to end of the menu. Note: To add a MenuItem that
invokes a command or callback it is better to use Menu.AddCommandItem or Menu.AddCallbackItem.
Note:It's preferable to use Menu.AddSubMenu in python for adding
sub-menu objects instead of invoking AddItem with
siMenuItemSubmenu.
Tip: See the C++ API and Python examples for creating a Simple Menu
plug-in to see this method in action.
oReturn = Menu.AddItem( Label, Style ); |
If the style is siMenuItemSubmenu the newly created Menu is returned. Otherwise the newly created MenuItem is returned.
Parameter | Type | Description |
---|---|---|
Label | String | The menu item label. |
Style | siMenuItemStyle | The menu item style, for example siMenuItemSubmenu. |