DefaultButton

DefaultButton[]

represents an OK button that closes a dialog, and is the default when TemplateBox[{return}, Key0, BaseStyle -> {Usage, FontWeight -> Plain, FontFamily -> Source Sans Pro}] is pressed in the dialog.

DefaultButton[action]

represents a button that is labeled OK, and whose action is to evaluate action.

DefaultButton[label,action]

uses label as the label for the button.

Details and Options

Examples

open allclose all

Basic Examples  (1)

Create dialog input, and use DefaultButton to dismiss dialog:

In[1]:=
Click for copyable input

Applications  (1)

Properties & Relations  (3)

See Also

Button  CancelButton  ChoiceButtons  PasteButton  DialogReturn  DialogInput  CreateDialog

Tutorials

Introduced in 2007
(6.0)