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 / Error handling - go to...
Power Automate
Answered

Error handling - go to next action doesn't seem to work

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi - using PAD 2.22.263.22202, I'm frustrated with this action that attempts to close an Excel instance. I didn't bother to check if it exists because I figured I could just depend on error handling to continue to the next action, but you see it stops.

 

Is it a bug or a misunderstanding on my part?

Thanks!

 

kelway_1-1661275498411.png

 

kelway_0-1661275443689.png

 

I have the same question (0)
  • MichaelAnnis Profile Picture
    5,727 Moderator on at

    The only acceptable errors for Close Excel are here, and these will be handled by the OnError parameter:

    https://docs.microsoft.com/en-us/power-automate/desktop-flows/actions-reference/excel#closeexcel

     

    MichaelAnnis_0-1661277301584.png

    The error you have is a parameter error which means you need to change the parameter.  Looks like a pre-run error.  If it is an error that occurs during the run, try an OnError action item and put it inside.

     

    Good luck!

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi Michael, 

    Thank you... What's happening is that the ExcelInstance hasn't been started yet because the error handler is being called before it's ever opened. I have this subflow as a general clean up anything that might exist.

     

    So if I understand you well, the "All Errors" is not really any error that might happen with that row? Clearly it seems so. I suppose I can solve just checking if ExcelInstance isn't empty and close it if so. I was just frustrated with move next on all errors not really doing that.

     

    This works:

    kelway_0-1661283301009.png

     

     

    Have a good one - thanks again!

  • VJR Profile Picture
    7,635 on at

    Your frustration is valid 🙂 as I have encountered many such Error Handlers that do not work as expected to trap the errors.

  • ryule Profile Picture
    929 Super User 2024 Season 1 on at

    Agreed; I have an Excel action where it's Error Handling absolutely does not work (below). It's supposed to go to a label upon a failure, but instead, it just fails the whole bot.

     

    ryule_0-1661350670191.png

     

    Luckily, I have a workaround to prevent the failure, using the conditional statement, but it'd be nice if the Error Handling just worked.

    ryule_1-1661350766210.png

     

     

  • Verified answer
    MichaelAnnis Profile Picture
    5,727 Moderator on at

    Correct...All Errors will (to my knowledge) only work if they are listed in the "Exceptions" section of the documentation of that action.  This is seen as "bad flow design" (not putting you down), because the variable is attempted to be called before it is set.  With that being said, I think an OnError action block would push it forward, but I could be wrong.

  • wnzn Profile Picture
    168 on at

    I would propose 'On block error' as well. It should catch all errors, not only the expected ones for the actions inside the block.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Thanks all... Yeah, I know it looks like bad practice - and maybe it is - but in this case it's a subflow to clean up in any case where there was an error.. so in the main flow that is in an error block, I call this one first to close Excel processes that may exist etc. I will try to additionally put the actions in that ErrorCloseAll subflow in a block - I think it's the correct way. 

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 June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 267 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 196

#3
Haque Profile Picture

Haque 182

Last 30 days Overall leaderboard