Show element
See also: Hide element, Form elements
Actions – Abstract
The action Show element sets the option 'Visible' for the linked Target element at runtime.
The action Show element sets the option 'Visible' for the linked Target element at runtime. This option must be set for an element to be effectively visible (see notes below). An element for which the 'Visible' option is not set is always effectively invisible.
►IMPORTANT◄ An element that is defined as 'required' must also be filled if it is effectively invisible. In contrast, any Validators configured for an element are only effective if the element is effectively visible. The action Show element may therefore influence not only the validation result of the element, but also the validation of parent elements up to the form.
The action can only be selected under Action type if a Target element is linked.
The 'Visible' option is available for all Form elements, so that any target element except the form element itself can be linked.
Background: Invisible elements are excluded from the validation. After a required field is shown, for example, no corresponding note is displayed. This is corrected by a new validation of all affected elements. However, it is recommended that this option is disabled if larger element hierarchies are displayed that do not require validation.
►NOTE◄
The action Show element only turns the Target element effectively visible at runtime, if all parent Element containers are also 'set to visible' in the form design.
If a Target element of an Element containers type turns effectively visible, then all child elements that were previously 'set to visible' (i.e. latently visible) also become effectively visible.
Example
In an input form for Shipments, the entry of an 8-digit batch number per package should be required at item level for certain packaging types. Only in this case should the relevant Repeatable element container and the input field for the 'Number of packages' appear at line item level.
Runtime example:
For the first line item, the Type of packaging 'IBC' was selected, for which batch numbers are required. The elements Number of packages and Batch no. are displayed.
The second item uses a Type of packaging without this requirement. The elements Number of packages and Batch no. are not displayed.
Configuration:
The batch numbers are stored in a plural Barcode attribute. The relevant Repeatable element container is linked to the Number of packages element as its 'Synchronized numeric element' (for details, see Repeatable element), so that the 'appropriate' number of repetitions always appears automatically for the barcode Text field (barcode) re-labeled as 'Batch no.' for this purpose. Adding or removing instances of the 'Batch no.' interactively via the
/
symbols is excluded by configuration.
The Number of packages and the Repeatable element container for Batch no.'s (aka. "Barcodes") are hidden by default in the form design.
|
For the Combobox Type of packaging, the behaviour displayed on the left is configured, which affects the Number of packages input field and the Barcode attribute container:
|