In many questionnaires, there may be a set of questions that are going to be asked repeatedly. These questions are known as “loops”. Loops are based on a count of how many times the same set of questions will be asked.
Step 1 - To create a list that can be used in a loop
Instructions for creating a list:
- At the bottom of the left-hand side of the “Build” page, there is an option that says “Lists”
- By clicking on the “+” next to “Lists” you can add your own list to insert into your answer choice options.
- Click on the list you’ve just created (in this example “Brand_List”) and it will open the screen where you can add your answer choices:
For more detail on Lists, please see this article
Step 2 – Create a section and add questions that need to be asked repeatedly. See this section for more detail on creating questions and question types in Survey Builder.
Step 3 – Click on “Section Options” and select the Loop section from the drop-down list.
Step 4 – Add _$cnt; in the question label
Step 5 – Loop question is ready, and it will repeat for all the answers listed in the list.
Looping based on the previous answer
- Follow all the sets mentioned above.
- Pass \PreviousQNo.a=$cnt; as filter condition on all the questions that need to iterate.
- If we have to pipe text then use {{loop}}
- To auto fill the loop iteration in a question, use $cnt; in answer control
- If you have to use the list in any question, click on the below icon and add it.