Enable/Disable Element in Data Design

Block Information

Available in: Page Flow

Toolbox Category: Dynamic Input

Block Type: Regular

Enable/Disable Element in Data Design is a regular block that allows you to enable or disable elements that were generated using the Content from Data Design block and dynamically added to the page or form.

When an element is disabled, it typically appears grayed out and the user cannot click on it or interact with it in any way. The specific behavior depends on the type of element it is applied to. Here are some common use cases:

  • Input and Multi-line elements: The user cannot enter or modify any value.

  • Dropdown element: The dropdown menu becomes non-selectable, and the user cannot change the selected option.

  • Checkbox and Toggle Switch elements : The user cannot toggle the state.

  • Button and Link elements: The user cannot trigger clicks/right-clicks, double-clicks.

The behavior of the block is similar to the Enable/Disable Element block, with some important differences:

  • Works only with elements generated using Content from Data Design block that are dynamically added.

  • Element Selection: You can only choose an element placed inside the selected Data Design element.

The block consists of the following (from top to bottom):

  • Data Design: Selectable Input to choose the Data Design element whose element you want to target.

  • Element: Selectable Input to choose the element, within the selected Data Design, you want to enable/disable.

  • ID: Optional Value Parameter that accepts a text value representing the unique value that was provided to the Content from Data Design block. See below for more details.

  • ID2: Optional Value Parameter that accepts a text value representing the secondary identifier that can be used to identify the desired element. See below for more details.

  • Data: Value Parameter that accepts a boolean (true/false) value where true represents the enabled state and false represents the disabled state.


ID and ID2 usage

The behavior of this block depends on the ID and ID2 value parameters and is detailed below:

  • ID and ID2 not provided: Operate on the selected element for all generated instances of the same Data Design element.

  • ID2 provided and ID not provided: Operate on the selected element for all generated instances of the same Data Design element with the same ID2 value.

  • ID provided and ID2 not provided: Operate on the selected element for all generated instances of the same Data Design element with the same ID value. Since we recommend the ID value to be unique, this would choose one from all the generated instances of the associated Data Design element.

  • ID and ID2 provided: Operate on the selected element for all generated instances of the same Data Design element with the same ID and ID2 value.


Usage Examples

NOTE: Please refer to the prerequisite information shown here before seeing the example.

The image below shows an example in which the state of the Input element (Input43) is set to disabled for Company 2, which is rendered with the ID ST101.

The result of the above example is highlighted below, where the Input element (Input43) is disabled for Company 2.

In the second example, we will illustrate the scenario where neither ID nor ID2 are provided. In this case, the system will disable the Input element (Input43) for all generated instances.

The result of the above example is highlighted below, where the Input element (Input43) is disabled for both the companies.

Last updated