Conditional logic allows you to show and hide questions in your form based on answers to other questions on the same form. This guide details how you can implement Conditional Logic within Custom Forms. If you would like to utilize Conditional Logic for your organization, please contact email@example.com.
For example, if you would like parents to choose from a list of schools in your district only if they have confirmed that their student is currently enrolled in the district, you would apply conditional logic. Here's how:
1. After giving your custom form a label and saving it, select "Custom Field" from the "Add new field" tab.
2. To use conditional logic, the field that the conditional question is dependent upon has to be a multiple choice or dropdown field. This is true for Standard Fields (e.g., "Is the student Hispanic?") as well as Custom Fields - both Standard ("Dropdown" and "Multiple Choice") and Awesome (e.g., "Yes No" "Gender").
3. In this example, the first question is a multiple choice question: "Does your student currently attend a school in our district?" (For more general information on setting up fields, please refer to the Editing a Custom Form: Field Settings article.)
4. Next, you would select the field for the conditional question. This is the question that will only be displayed based on the answer to the previous question. The field can be of any type, but in this example, we're using a dropdown field.
5. The dropdown list will be a list of schools for the parent to choose from, but only if she has answered yes to the question, "Does your student currently attend a school in our district?"
6. To turn on conditional logic, you would check the "Add Conditional Logic" checkbox in the field settings menu of the conditional question. After checking that checkbox, you would select the previous question that the current question is dependent upon. (Note: there may be more than one available question if you have other multiple choice or dropdown fields in your form.)
7. After selecting the desired previous question, select the answer to that question that will cause the conditional question to be displayed in the form. In this example, we want to display the "Please choose the student's school" field only if the answer to "Does your student currently attend a school in our district?" is "Yes."
8. That's all! Now when parents use this form, they will only see one question at first. However, if the answer to that first question is "Yes," they will see the second question.
If the answer is "Yes," the second question appears:
If the answer is "No," the second question doesn't appear (or disappears if the answer was changed from "Yes"):
Nesting Conditional Logic
Also, if you would like to add a conditional question based on the answer to the second question in example (i.e., "nesting" a conditional question), you would use the same process. For example, if you would like to ask the parent for scholarship information based on the school selected in the second question, you could use the steps below:
Adding additional logic to a question
Finally, you aren't limited to creating conditions that are satisfied with just one question and one answer. You can use the "Add Additional Logic" button to add additional conditions to a questions. An example would be displaying the same scholarship question for multiple answers selected from the previous school dropdown question:
You can then click + Add Additional Logic:
And add the second answer that ties back to the same logic!
The best way to test the conditional logic you've implemented is to view your form. For more information see the "Viewing a Custom Form" article.