Selected items of grid
The Behaviour type Selected items of grid checks a specific element to be evaluated (Data grid or other List elements) for the presence of a selection and returns selected objects as an array, if any.
The element to be evaluated is determined as follows, depending on the existence of an element link for the behaviour:
If no element is linked, then the executing element of the behaviour is examined.
If an element is linked, then the linked element is examined.
Actions on ‘true’ are executed if the following conditions are met:
The element evaluated belongs to the group of List elements.
There is a selection for the element evaluated, that is, at least one element is selected.
For Actions on ‘true’, the data of all selected objects is available as an array. A single selected object is 'wrapped' into an array as well.
In all other cases, Actions on ‘false’ are executed, when two different cases of data are to be differentiated:
If the element evaluated is a list element without any selection, the behaviour data is empty ($null).
If the element evaluated is not a list element, any existing behaviour data is passed on unchanged.
Specific notes for different types of List elements
Relevant for Notes |
Tree element |
|||
The behaviour Selected items of grid is only useful for list elements that support selection. |
|
|
|
|
To inspect an element allowing single selection only, it is often more useful to choose the behaviour Selected item of grid instead, unless the selection should be transformed into an array for technical reasons. |
|
|
|
|
For list elements for which selection is the value of the element, the behaviour may report ‘items’ as selected that are not (or no longer) contained in the list. |
|
|
|
|