InsertSeparator

int InsertSeparator (int menuBarHandle, int menuID, int beforeMenuItemID);

Purpose

Inserts a new separator bar in a menu, and returns a menu item ID you can use in subsequent function calls to specify the separator.

Parameters

Input
Name Type Description
menuBarHandle integer Specifier for a particular menu bar that is currently in memory. You obtain this handle from LoadMenuBar or NewMenuBar.

If the menu bar was automatically loaded through LoadPanel, use GetPanelMenuBar to get the menu bar handle.
menuID integer ID for a particular menu within a menu bar. The ID must be a constant name, located in the .uir header file, that you assign in the User Interface Editor or a value that you obtain from NewMenu.
beforeMenuItemID integer Menu item ID above which to insert the separator bar. To place the separator at the bottom of the menu item list, pass –1.

Return Value

Name Type Description
menuItemID integer Returns the ID that you use to specify this menu item in subsequent function calls. Negative values indicate that an error occurred. Zero is not a valid ID.

Code Error Message String
xx (Menu item ID) Success