Depending on the requirements of the form you are building or editing, additional settings are available which can be configured to build more dynamic and robust data-driven forms.
Conditions allow you to configure settings which can control the appearance, state, or validation of elements or pages on your forms. For example, you could:
- Set the visibility of a field/page
- Enable or disable fields
- Lock fields to read-only
- Make fields required or optional
Conditions work by using logic statement(s) to apply these settings, basically:
IF [this] THEN [do] THAT
An example could be if you have a form which captures the user/patron's preferred contact method, and you want to ensure they enter their email address when the email option is selected. You can add a condition that sets the Email field required when the email option is selected from the preferred contact method element.
IF [Preferred Contact Method = Email] THEN [make required] THAT [Email Address]
Configuring Conditions
There are many scenarios and variables that may warrant the use of conditions, the instructions below will describe how to add a condition for the preferred contact > email address example described above, by editing the element on a pre-created form.
For more information on how to create forms and add new elements, please see the Create Easy Forms article.
- Navigate to the field you are adding the condition to, then click Edit
- For this example, the condition is added to the Email Address field, to make it required when the preferred contact method selected is Email
- In the window that opens, click the Conditions tab
-
State, select the most appropriate value indicating the desired state for the field
- For this example, select Required
- This field will be "required" when the appropriate condition(s) are met
- For this example, select Required
-
Element, select the appropriate values describing how the element relates to the condition
-
"If" drop-down, select the most appropriate option that describes when the condition should be triggered
-
All - means all field conditions must be met for the function to work
- For this example, select "all", the other options are more applicable when multiple conditions are being added
- Any - means any of the field conditions can be met for the function to work
- One - meansonly one of the field conditions must be met for the function to work
-
All - means all field conditions must be met for the function to work
-
"Element" drop-down, select the element (field) that will trigger the condition
- For this example, we would select the "Preferred Contact Method" element
-
"If" drop-down, select the most appropriate option that describes when the condition should be triggered
-
Trigger/Value, select the trigger and value options that will enact the condition
-
Trigger drop-down, select the option that will validate the data entry
- For this example the most appropriate would be "Value Is" because we want the condition to trigger when as specific value is selected
-
Value drop-down, select the element (field) value that triggers the condition when selected
- For this example, select the Email value
-
Trigger drop-down, select the option that will validate the data entry
- Click Save
-
State, select the most appropriate value indicating the desired state for the field