0

I have a list of items in it.

I created a while loop that does the following:

While Current Item: Status not equals Released: send an email every day

What I want to do instead is if there is no need to "release", users can choose a status called "No need to release" and that would also break the loop

so something like:

break the loop if Current Item: Status equals Released OR if Current Item: Status equals No need to release.

If there is a way in SharePoint Designed to add a step that would end the workflow directly that would work too. I just want the workflow to end if status = released or if status = no need to release

1 Answer 1

1

The most straightforward way will be adding a dummy variable (I will call it Stopper) for the loop. The while loop will be like While Stopper is false: send email every day

So at the beginning part of the workflow we set the stopper to be false. Then we will definitely run the loop for first time. Inside the loop, we add if conditions,

  1. if Current Item: Status equals Released OR if Current Item: Status equals No need to release
  2. Set workflow stopper to true

Then next time, the loop will break.

Also, you can at the very beginning of the workflow, add the same if condition for the stopper variable, so we can make sure the loop always run when it is needed.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.