Main Content

Simulink.dialog.Button Class

Namespace: Simulink.dialog
Superclasses: Simulink.dialog.Control

Create instance of button dialog control

Description

The Simulink.dialog.Button class is a handle class that enables you to manage button dialog control.

The Simulink.dialog.Button class is a handle class.

Properties

expand all

Identifier of the button dialog control, specified as a string scalar or character vector.

Example: 'Control1'

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: char | string

Display text of the button dialog control, specified as a string scalar or character vector.

Example: 'Signal 1'

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: char | string

MATLAB code executed when you click the button dialog control, specified as a character vector.

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: char

Filename of image shown on the button dialog control, specified as a string scalar or character vector. The file must be located on the MATLAB path.

Example: 'model.png'

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: char | string

Placement of button dialog control, specified as 'new' or 'current'.

  • 'new' — Place the button dialog control in a new row on the mask dialog box.

  • 'current' — Place the button dialog control in the same row as the previous dialog control on the mask dialog box.

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: char | string

Option to edit the button on the mask dialog box, specified as 'on' or 'off'.

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: logical

Option to display the button on the mask dialog box, specified as 'on' or 'off'.

Example: 'on'

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: logical

Option to control the horizontal stretch of the button dialog control when you resize the mask dialog box, specified as 'on' or 'off'.

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: logical

Informative message that appears when you point to the button on the mask dialog box, specified as a string scalar or character vector.

Example: 'Click to select'

Attributes:

GetAccess
public
SetAccess
public
GetObservable
true
SetObservable
true

Data Types: char | string

Alternatives

You can manage a button dialog control using the Parameters & Dialog pane in the Mask Editor dialog box. For more information, see Parameters & Dialog Pane.

Version History

Introduced in R2013b