Skip to main content

I created a Loop, if attachment is not attached the workflow pauses and sends notification the attachment is needed.  I created a Pause For - to be an hour.

When validating the workflow:

1. The notification of attachment needed fired.

2. The workflow paused.

3. I edited request and added attachment within the first hour.

4. After the hour the workflow started.

5. I received notification of attachment needed. (should not have)

 

It appears the Loop did not recognize the attachment had been added with the first hour. Should it?   After the second hour pause, it picked up the attachment had been added and move the workflow forward.

 

Am I missing something?

 

Thanks,

Suzanne

If you could screen shot your flow it would help a lot.   It probably has to do with the condition of looping / breaking out of the loop.

Thanks


129122_pastedImage_3.png

129120_pastedImage_1.png

129121_pastedImage_2.png


So the way this will technically work is:

Workflow will enter your Loop and check the condition before actually executing anything inside of your loop.  If condition says to move forward into the loop:

Next it will execute your Pause for 1 hour.

Email Will be sent.

Second pause takes place.
Loops back and checks condition again to see if this should be repeated.

The Loop will not immediately exit until it performs its full cycle.   There is no "break" from loop so to speak.

Does that make sense?

Thanks,

Mike


Yes, to a point.  I still don't understand why I received the second notification.  After it paused the first time, should it have picked up the attachment was there?  Do I need to remove the send notification I have before the Loop starts? 


I'd need the details of the notifications to be able to track down which one was sent, but looking at your logic you have a total of 3 notifications on the "no" branch of the set condition.  Assuming it enters the loop, you will get at least 3 notifications / and possibly more if it loops more than once.


Set a condition = If attachment value equals yes then the workflow goes through.

If the condition is not met:

1. The notification of attachment needed is sent.

2. Update item to pending status.

3. Loop

4. Pause for an hour ( it will be 24 hours when live)

5. If condition not met in an hour send notification of attachment needed again.

6. This continues until the attachment equals yes.

When I validated the workflow:

1, 2, 3, and 4 occurred

I added the attachment during the first pause.

When the first pause was over, it did not recognize that attachment was there and step 5 occurred.

I guess I am not understanding why it seems it did not look for the attachment after the first pause.


The reason why is because you are still inside the loop.  Think of the loop as a circle with a single point at the top where the condition is checked.  The logic moves all the way around the perimeter of the circle until it reaches that top point again and checks.   Think of your actions inside the loop as sitting along this perimeter and being encountered as you move around the circle.

 

If you want to check after the first pause, put the send notification inside of another RUN IF statement and your problem should be solved. I don't think you need that second pause as this will become clear now that Loops are better understood

 

Thanks,

Mike


Mike,

Awesome! I updated as shown below and it worked!  Thanks Mike for taking the time to help me wrap my head around this!

129389_pastedImage_0.png


Reply