CommandBarButton.Caption Property
Gets or sets the caption text for a command bar control. Read/write.
Note
|
|---|
| The use of CommandBars in some Microsoft Office applications has been superseded by the new Ribbon user interface. For more information, search help for the keyword "Ribbon." |
Syntax
expression.Caption
expression A variable that represents a CommandBarButton object.
Return Value
String
Note
|
|---|
| A control's caption is also displayed as its default ScreenTip. |
Example
This example adds a command bar control with a spelling checker button face to a custom command bar, and then it sets the caption to "Spelling checker."
| Visual Basic for Applications |
|---|
|
Note