GefContextMenuItem.SetActionToPointTarget (method)

Makes the menu item trigger a point target command.
Syntax: Boolean = object.SetActionToPointTarget ( PointTargetIndex )
Parameters:
PointTargetIndex As long -
Description: The SetActionToPointTarget makes the menu item trigger a point target command. It may return False of the index is out of range. The default valid values are 0, and 1. If additional point targets have been installed other values will be valid.

Example:

Sub OnPreContextMenu(oContextMenu As GefContextMenu)
  Dim oContextMenuItem As GefContextMenuItem
  Dim oMenuItems As GefContextMenuItems
  
  Set oMenuItems = oContextMenu.MenuItems
  Dim oSubMenu As GefContextMenu
  
  Dim oSubMenuItem As GefContextMenuItem
  Set oContextMenuItem = oMenuItems.Add
  
  oContextMenuItem.MakeSubMenu
  
  oContextMenuItem.Text = "Point Targets"
  
  Set oSubMenu = oContextMenuItem.SubMenu
  
  Set oSubMenuItem = oSubMenu.MenuItems.Add
  oSubMenuItem.SetActionToPointTarget 0
  oSubMenuItem.Text = "Point Control Panel"
  
  Set oSubMenuItem = oSubMenu.MenuItems.Add
  oSubMenuItem.SetActionToPointTarget 1
  oSubMenuItem.Text = "Quick Trend"
End Sub