|www.progui.co.uk Top Previous Next|
Success = InsertMenuItemEx(Menu.i, Position.l, NewItemID.l, Text$, *NormalImageID, *HotImageID, *DisabledImageID, Submenu.i)
Inserts a new menu item into a previously created MenuEx.
Menu.i is the handle/ID of the menu. Position.l is the index in the menu of where you would like the new item to be inserted (zero being the first item). Specifying '-1' for Position.l will place the new item at the end of the menu. NewItemID.l is the ID you would like to associate with the item. Text$ is the new text you want the item to display and can contain rendering effect "escape codes" (see MenuItemEx). *NormalImageID, *HotImageID and *DisabledImageID are optional pointers to the icon image data for the item and can be null. Submenu.i is the optional handle/ID of the new sub menu to be attached and can be null.
Returns true for success or false for failure.