title | keywords | f1_keywords | ms.assetid | ms.date | ms.localizationpriority | |
---|---|---|---|---|---|---|
CommandButton object (Outlook Forms Script) |
olfm10.chm2000490 |
|
bb2bcfaa-e7a5-cedc-2ed7-bcc17a4d8fb6 |
06/08/2017 |
medium |
Starts, ends, or interrupts an action or series of actions.
The macro or event procedure assigned to the CommandButton control's Click event determines what the CommandButton does. For example, you can create a CommandButton that opens another form. You can also display text, a picture, or both on a CommandButton.
The only event for a CommandButton is the Click event.
Name | Description |
---|---|
Click | Occurs when the user clicks inside the control. |
Name | Description |
---|---|
Accelerator | Returns or sets the accelerator key for a control. Read/write. |
AutoSize | Returns or sets a Boolean that specifies whether an object automatically resizes to display its entire contents. Read/write. |
BackColor | Returns or sets a Long that specifies the background color of the object. Read/write. |
BackStyle | Returns or sets an Integer that specifies the background style for an object. Read/write. |
Caption | Returns or sets a String that appears on the button to describe what it does. Read/write. |
Enabled | Returns or sets a Boolean that specifies whether a control can receive the focus and respond to user-generated events. Read/write. |
ForeColor | Returns or sets a Long that specifies the foreground color of an object. Read/write. |
Locked | Returns or sets a Boolean that specifies whether a control can be edited. Read/write. |
MouseIcon | Returns a String that represents the full path name of a custom icon that is to be assigned to the control. Read-only. |
MousePointer | Returns or sets an Integer that specifies the type of pointer displayed when the user positions the mouse over a particular object. Read/write. |
Picture | Returns a String that specifies the full path name of a bitmap to display on a control. Read-only. |
PicturePosition | Returns or sets an Integer that specifies the location of the picture relative to its caption. Read/write. |
TakeFocusOnClick | Returns or sets a Boolean that specifies whether a control takes the focus when clicked. Read/write. |
WordWrap | Returns or sets a Boolean that specifies whether the contents of a control automatically wrap at the end of a line and the control expands to fit the text. Read/write. |
[!includeSupport and feedback]