Creating a Standard Loop

A standard loop is indicated by a symbol.

Click the Loops tab to set the details of the loop:

Set the following parameters as appropriate for the loop you want to create:

  • Test Time
     Select either Before or After. The Before option is equivalent to the programming construct "while": the expression is evaluated before the activity is performed, and therefore if the expression evaluates to False, the activity is not performed. The After option corresponds to the programming construct "Do: while": the expression is evaluated after the activity has been performed, guaranteeing that the activity is performed at least once.
  • Loop Maximum
     Optionally specify an integer to control the maximum number of times the activity is performed. In the event of conflict between Loop Maximum and the result of the Javascript defined under Script Defined As, the Loop Maximum will override the script calculation.
  • Script Defined As
     Select one of the following options:
    • Free Text
        Allows you to describe how you would like the loop to be tested if you prefer to leave the specific implementation of the loop expression to someone else.
      Note: A BPMN warning is generated if you leave the script area blank. To remove the warning, enter a text description of the intended script implementation.
    • JavaScript
       Allows you to enter JavaScript that will be evaluated for the loop expression.
    • Unspecified
       Allows you to specify that there is no expression or description for this loop.