--- title: Add Conditional Logic to a Form meta_tier: Advanced-Enterprise source_file: Published/115005432466.html url: https://docs.truecontext.com/1374411/Content/Published/115005432466.html last_updated: '2026-03-09' word_count: 366 --- # Add Conditional Logic to a Form Conditional Logic uses “If This, Then That” statements to add intelligent automation to forms. Conditional Logic defines how form elements behave based on input from a mobile user. For example, based on the answer to one question, other questions might be hidden, shown, required, cleared, or assigned a specific value. This topic describes how to build Conditional Logic rules into a form. Available on all tiers: Digital Intelligent Elite [?](https://truecontext.com/pricing/) ## Video ## Add a Rule 1. Open the Form BuilderThe Form Builder is the tool that form designers use to create forms. In the Form Builder, accessed from the TrueContext Web Portal, form designers can add and edit pages, sections, and questions, as well as attach data destinations and configure the form's settings.. 2. Ensure you have created all the questions/sections/pages that will be involved in your Conditional Logic rule. 3. Select **Conditional Logic** > **Add a Rule**. 4. Enter a **Rule Name** (required) and **Rule Description** (optional). 5. In the **If** statement, define the condition that must be met to trigger the actions. This might be a specific answer to a single question or a combination of answers to multiple questions. 6. In the **Then** statement, define what the form should do when the **If** statement is true. You can show or hide pages and sections and show, hide, require, clear, or assign values to questions. Some Conditional Logic rules have multiple **Then** statements. If your rule has a long list of **Then** statements, organize the statements to run in a logical order. To move a **Then** statement, select the handle to the left of the statement and drag the row to a new place. You can also add a new **Then** statement anywhere in the list. Hover between two **Then** statements and select the plus sign [+] to add a new statement. The topic [Best Practices for Conditional Logic Rules](ConditionalLogicBestPractices.md) describes the benefits of reordering **Then** statements in more detail. 7. **Else** statements define what the form should do when the **If** statement is false. The form automatically builds **Else** statements that undo the **Then** statements. (Optional) To add, change, or delete one or more **Else** statements, select **Custom Actions**. 8. Save the form. To make sure your Conditional Logic rules work as intended in the field, test them thoroughly before you deploy the form. Test the form under a variety of conditions to validate the field user experience.
Downloading 115005432466.md… Go back