Stop Command/Terminate Flow

Options

I am working on a flow that contains multiple search conditionals and loops. For a couple of the conditional outcomes I want the flow to terminate immediately without generating a ‘failed’ status. Does anyone know how to accomplish this?

Comments

  • Hey Austen, have you seen the “Terminate” action? You can specify how you want to terminate a flow, and change the status to Succeeded if desired:

    c0d393f355db1220e8072cbd363d13e7-origina
    c492408861be12c0340c4d464f671b77-origina
  • Austen Brown
    Austen Brown Community All-Star
    Ninth Anniversary Kudos 5 Name Dropper Participant

    Hi @Ben Lambert - When I try to add it I get the error message “The operation 'terminate' cannot be used inside a for each”. I have attached a diagram of the flow to better illustrate where I am trying to add this within the flow - see section IV, loop 4, response ‘Do Nothing’.

    Form to NXT Diagram 5.0.pdf

  • Hey Austen, sorry I missed the nuance about wanting to terminate the flow within the loop. You're right, you can't use a Terminate action within a loop. I did some quick searching and found that others have hit this problem as well, and you may find some workarounds in some of the links here:

    I think most of them involving using a Do…Until loop and setting a flag when the loop should be exited, and then afterwards using the Terminate action if the flag is set. Not ideal (or elegant?) but maybe an option for you.

Categories