web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Try Previous step agai...
Power Automate
Unanswered

Try Previous step again if stuck/error within a loop

(0) ShareShare
ReportReport
Posted on by 21

Hi,

 

I am new here and have started some automation via desktop automate. I have been tasked with retrieving pdf attachments on invoices from our web-based ERP system. There are times where depending on web connection speed, the flow step executed much faster and it times out. It usually occurred in my loop, for example, 

  • Go to URL
  • Click on icon
  • wait
  • right-click on the embedded container with pdf
  • key press - right click save -as {usually around this part is where it freezes up if page loads to slow}

is there a way if it is stuck to repeat the last step and have it right click again?

 

Thanks!

I have the same question (0)
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi,

    You can add error handling to many actions. Click the "On error" button in the bottom left. See below:

     

    retry action2.pngretry action.png

  • weebot Profile Picture
    21 on at

    Hi, yes thanks. Was aware of that!

    What I meant was how to repeat the previous action that was before, not the current action, hope that make sense!

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi,

    Yes that makes sense.

    You can try adding a "Label" before the action you want to repeat.

    Than simply add error handling -> "Go to label" in the action that fails.

    Beware that this could result in an infinite loop 😁 You may want some type of "counter" or timeout to avoid this.

    Repeat prev action 3.pngrepeat prev action.png

  • MichaelAnnis Profile Picture
    5,727 Moderator on at

    You can surround the steps you expect to error out in an "On block error". 

    MichaelAnnis_1-1673019279003.png

     

    Then in the parameters, you can tell it to "continue flow run" and "go to beginning of block", so any error in this block will reset back to the first action. 

    MichaelAnnis_0-1673019233327.png

    Be careful, because this can end up in an infinite loop if a situation exists where it errors out every time.  It would be best practice to set a limitation.  You can do this by setting a counter at the beginning of your flow and adding one each time the error resets, then you can set a limitation whether to proceed or not:

    MichaelAnnis_2-1673019550389.png

     

     

     

  • weebot Profile Picture
    21 on at

    These are all good ideas, thanks all! I will try these.

  • DivyaSingh2609 Profile Picture
    2 on at

    Hi @MichaelAnnis 

     

    What if I want a same actions to be repeated in error of every action in my loop 

    Suppose my actions are working fine

    But I have session time out popup after 20-30min

    And I want to click on continue 

    So I want this to be over every action on error under my loop

    And once the UI element for continue is clicked 

    I want to to again try to repeat the action where error occurred,,

     

    Is it possible ??

  • MichaelAnnis Profile Picture
    5,727 Moderator on at

    You can run error subflow and then repeat action:

    MichaelAnnis_0-1718410402310.png

    click on New Rule to run subflow, but then select continue flow run and repeat action to set this up.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 272 Super User 2026 Season 2

#2
trice602 Profile Picture

trice602 147 Super User 2026 Season 2

#3
11manish Profile Picture

11manish 146 Super User 2026 Season 2

Last 30 days Overall leaderboard