Simulink.dialog.TreeControl class

Package: Simulink.dialog

Control Tree control programmatically

Description

Use an instance of Simulink.dialog.TreeControl class to perform the following operations:

  • Get selected items from the tree

  • Set selected items in the tree

Properties

Name

Uniquely identifies the dialog control and is a required field.

Type: character vector or string

Prompt

Specifies the text displayed on the tree dialog control.

Type: character vector or string

Default: empty

TreeItems

Specifies the items shown in the tree.

Type: cell array

Default: empty

Callback

Specifies the MATLAB® command (s) to be executed when the dialog control is invoked.

Type: character vector or string

Default: empty

Row

Specifies whether dialog control is placed on the current row or on a new row.

Type: character vector

Value: 'current'|'new'

Default: 'current'

Enabled

Indicates whether tree control is active on the mask dialog box.

Type: boolean

Value: 'on'|'off'

Default: 'on'

Visible

Indicates whether tree control is displayed on the mask dialog box.

Type: boolean

Value: 'on'|'off'

Default: 'on'

Multiselect

Indicates whether tree control is enabled for multiple selection.

Type: boolean

Value: 'on'|'off'

Default: 'on'

Tooltip

Indicates whether tree control has a tooltip configured.

Type: character vector or string

Default: empty

Methods

getSelectedItems(TreeControl)Get the values of selected items from a tree hierarchy
setSelectedItems(TreeControl)Set values for a tree