Caption property

Microsoft Visio Developer Reference

Caption property

       

Gets or sets the caption for an object.

Version added

4.0

Syntax

object.Caption = stringVal
stringVal = object.Caption

object

Required. An expression that returns an object in the Applies to list that has or gets the caption.

stringVal

Required String. The caption of the object.

  • Use & in the string to cause the next character in the string to become the shortcut key for that menu or menu item, For example, the string "F&ormat" causes o to become the shortcut key for that menu item in that one menu.
  • Use "" in the string to display a double quotation mark on the menu.
  • Use && in the string to display an ampersand on the menu.

Remarks

Visio does not use the Caption property of a MenuSet or ToolbarSet object.