Object: CommandBarButton Object
Access: Read/Write
Sets or returns the target COM object associated with the commandbar button.
CommandBarButton.Target = COM Object
The name of the COM object associated with the commandbar button.
'
' This example add a menu entry to execute a method defined in the script
'
' With the menu controls collection
Set button = myMenuCtrls.Add
button.Caption = "Zoom Selected"
'The target COM object is this scripting engine
button.Target = ScriptEngine
button.ExecuteMethod = "myZoomSelectedMethod"
button.DescriptionText = "Zoom around selected objects"
Sub myZoomSelectedMethod( )
' zoom around selected objects
doc.ActiveViewEx.SetExtentsToSelection
End Sub