AddMasterSeparatorItem
PowerScript function
Description
Adds a menu separator to the master menu of the application
menu.
Applies to
RibbonApplicationMenu controls
Syntax
1 |
controlname.AddMasterSeparatorItem ( { Long ParentIndex } ) |
Argument |
Description |
---|---|
controlname |
The name of the RibbonApplicationMenu control into which |
ParentIndex |
The index of the menu item (RibbonMenuItem) into which you It cannot be an index of a separator. If not specified, a |
Return value
Long.
Returns the position of the new item if it succeeds and -1 if an
error occurs. If any argument’s value is null, returns null.
Usage
The menu separator is a horizontal line used to visually distinguish
between groups of menu items. The separator can only be added in the
master menu of RibbonApplicationMenu (AddMasterSeparatorItem) or in
the menu of RibbonMenu (AddSeparatorItem); it cannot be
added to the recent menu of RibbonApplicationMenu.
Examples
This example inserts a menu separator below the “Account” master
menu item and inserts another menu separator in the submenu of
“Account”.
1 2 3 4 5 6 |
Long ll_Return, ll_Index RibbonApplicationMenu lr_AppMenu ll_Return = lr_AppMenu.AddMasterSeparatorItem() ll_Index = lr_AppMenu.InsertMasterItemFirst ("Account", "AccountBig!", "Ue_AccountMasterItemClicked") ll_Return = lr_AppMenu.AddMasterSeparatorItem (ll_Index) |
See also