HOW TO
This article shows how to change the caption for a UIToolControl using VBA and ArcObjects.
Note:
Code in ThisDocument module will only run in the current map document. To store the code in all your map documents, open the Normal.mxt ThisDocument code module.
Code:
Sub ChangeToolProperties()
Dim pCommandItem As ICommandItem
Dim pApp As IApplication
Set pApp = Application
Set pCommandItem = Project.ThisDocument.CommandBars.Find("Project.UIToolControl1")
' Change the tool's caption
pCommandItem.Style = esriCommandStyleTextOnly
pCommandItem.Caption = "My Tool"
' Refresh the command
pCommandItem.Refresh
End Sub
Get help from ArcGIS experts
Download the Esri Support App