Accusoft ImagXpress 13
MenuAddItem Method
Top-level menu Id for this menu item. A menu id of 4100-4200 is reserved for adding a menu separator bar.
A long value that will be passed back in a MenuSelect event.
A long value that will be passed back in a MenuSelect event.
Description
Adds an item to a specified menu.
Syntax
Visual Basic
Public Sub MenuAddItem( _
   ByVal Menu As enumMenu, _
   ByVal Tool As enumIXTool, _
   ByVal TopMenuID As Long, _
   ByVal SubMenuID As Long, _
   ByVal MenuText As String, _
   ByVal User1 As Long, _
   ByVal User2 As Long _
) 
Parameters
Menu
ValueDescription
Menu_ContextContext menu activated.
Menu_ToolbarToolbar menu activated.

If the menu is Toolbar, the Tool parameter is the Tool ID that the menu is associated with.

If the menuType is Context, then the Tool parameter has no meaning and can be any value.

Tool
ValueDescription
TOOL_HandImage panning tool.
TOOL_MagMagnifying window.
TOOL_MouseWheelHorizScrollMouse wheel horizontal scroll.
TOOL_MouseWheelVertScrollMouse wheel vertical scroll.
TOOL_MouseWheelZoomMouse wheel zoom.
TOOL_NoneNo tool selected.
TOOL_PanImage viewing pan tool.
TOOL_SelectRubberband window selection tool.
TOOL_ZoomInZoom in tool.
TOOL_ZoomOutZoom out tool.
TOOL_ZoomRectZoom rectangle tool.
TopMenuID
Top-level menu Id for this menu item. A menu id of 4100-4200 is reserved for adding a menu separator bar.
SubMenuID
Sub-level menu Id for this menu item, if this is to add a sub-level menu item otherwise this parameter should be 0.
MenuText
The text that will be displayed for this menu item.
User1
A long value that will be passed back in a MenuSelect event.
User2
A long value that will be passed back in a MenuSelect event.
Remarks

The MenuAddItem method adds a new menu item to the specified menu. If the Menu is Toolbar, then the Tool parameter is the Tool ID that the menu is associated with.

If the Menu is Context, the Tool parameter has no meaning and can be any value.

If the menu item is to be a top-level menu item, then the SubMenuID should be 0. A SubMenuID menu item can only be added when a TopMenuID has been added with a previous SubMenuID set to 0.

Note: The Toolbar must be activated before any context menus can be modified.

See Also

ImagXpress Object  | ImagXpress Members

 

 


©2019. Accusoft Corporation. All Rights Reserved.

Send Feedback