TreeListBase.setSelectedForNodes

Syntax

setSelectedForNodes(nodes, value, fireEvents, ignoreRules);

Parameters

nodes. Array of String. Array of node keys.

value. Boolean. Set value.

fireEvents. Boolean. Generate event on value changed. By default it is set to true.

ignoreRules. Boolean. Ignore rules. By default it is set to false.

Description

The setSelectedForNodes method selects the specified array of nodes.

Example

Executing the example requires the SimpleTreeList component with the Tree identifier (see Example of Creating the SimpleTreeList Component).

// Select specified nodes
Tree.setSelectedForNodes([0, 2, 4], true);

After executing the example specified nodes are selected.

See also:

TreeListBase