Button

Represents a button control.

A Button can be clicked by using the mouse, ENTER key, or SPACEBAR if the button has focus.

Set the AcceptButton or CancelButton property of a Form to allow users to click a button by pressing the ENTER or ESC keys even if the button does not have focus. This gives the form the behavior of a dialog box.

When you display a form using the ShowDialog method, you can use the DialogResult property of a button to specify the return value of ShowDialog.

For a full list of properties, methods and events see the API documentation.

Features

Icon

An icon can be shown on the button by setting the Image, ImageList or or ImageSource property. After setting, the icon and text spacing can be increased or decreased by setting the ImageSpacing property.

Supports HTML

The Button control supports entering custom HTML for it's value. Just set the AllowHtml property to true. The below example contains text using the <del>, <h2>, and <bdo> tags.

Repeat

The Repeat functionality allows a button to raise it's Click event repeatedly from the time it is pressed until it is released.

Advanced

JavaScript Widget

ItemDescription

Class name

"wisej.web.Button"

Theme appearance

"button", see Themes.

Child components

"icon" is the button's icon, if shown. "arrow" is the dropdown icon on a button with MenuItems set. See JavaScript.

Source code

Last updated