Add a loopΒΆ

It is often useful to repeat a certain set of questions multiple times in a survey. Colectica supports three different types of loops.

RepeatWhile

Repeat a section as long as specified condition remains true

RepeatUntil

Repeat a section until a specified condition becomes true

Loop

Similar to a While loop, but also allows you to specify initialization code

  1. Click the Add an item button.

    ../../../../_images/add-item-button-loop.png
  2. In the popup menu, click the button corresponding to the type of loop you would like to create.

    ../../../../_images/add-item-popup-loop.png
  3. A new loop is created and its editor is opened.

  4. Enter the condition that must remain true for your loop to continue executing.

  5. To add questions or other nested items within the loop, click the drill into button for your loop.

    ../../../../_images/drill-into-sequence-button.png
  6. You will be taken to an empty survey designer. Anything you add here is only applicable to your chosen branch.

    ../../../../_images/sequence-designer.png
  7. To go back to the top level of your questionnaire, use the breadcrumb bar.

    ../../../../_images/sequence-breadcrumbs.png