CommandButton control

This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.

                                            

Starts, ends, or interrupts an action or series of actions.

Remarks

Requires VBScript.

Syntax

Sub CommandButton_Click( )

**'**write event code here

End Sub

The macro or event procedure assigned to the CommandButton'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 default property of a CommandButton is the Value property.

The only event for a CommandButton is the Click event.