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 / Launch Excel in On blo...
Power Automate
Answered

Launch Excel in On block error retry fails

(0) ShareShare
ReportReport
Posted on by 10

I have a desktop subflow that tries to launch a spreadsheet. Sometimes the actions in the spreadsheet fail so I want to to try the set of actions up to 5 times.

 

The first time through the subflow Launch Excel works just fine, but if something fails, and the On block error starts over, the Launch Excel command fails with error "Failed to open Excel document '' (Workbooks retrieval error)" even though in the previous iteration it opened fine. Any suggestions?

 

sschoenherr_0-1674683836956.png

 

I have the same question (0)
  • Verified answer
    Highboy Profile Picture
    1,187 Super User 2024 Season 1 on at

    I think the problem is that you are killing your excel instance, and then try to open a file and connect to the excel instance you just killed.

    Highboy_0-1674736405399.png

     

  • Sivapriya Profile Picture
    9 on at

    I am using Launch Excel in Power Automate desktop. It is working when i run in attended mode. When i call this desktop flow in Cloud flow, I am getting following error:


    "message": "Problem while executing action 'LaunchAndOpenUnderExistingProcess'. Failed to open Excel document 'C:\\Users\\MuruganSivapriya(Asp\\OneDrive - ArchKey Solutions\\Documents\\PO Import Process\\Config\\Company.xlsx' (File related error). \r\n \r\nMicrosoft.PowerPlatform.PowerAutomate.Desktop.Actions.SDK.ActionException: Failed to open Excel document 'C:\\Users\\MuruganSivapriya(Asp\\OneDrive - ArchKey Solutions\\Documents\\PO Import Process\\Config\\Company.xlsx' (File related error). ---> System.IO.FileNotFoundException: documentPathSafe\r\n at Microsoft.Flow.RPA.Desktop.Modules.Excel.Actions.ExcelActions.<>c__DisplayClass15_0.<LaunchExcel>g__SetActiveWorkbook|1()\r\n at Microsoft.Flow.RPA.Desktop.Modules.Excel.Actions.ExcelActions.LaunchExcel(Variant documentPath, Variant readPassword, Variant writePassword, Variant& excelInstance, Int32 launchMode, Boolean visible, Boolean loadAddInsAndMacros, Boolean needsAuthentication, Boolean readOnly, Boolean launchInNewInstance, String& version)\r\n --- End of inner exception stack trace ---\r\n at Microsoft.Flow.RPA.Desktop.Modules.Excel.Actions.ExcelActions.LaunchExcel(Variant documentPath, Variant readPassword, Variant writePassword, Variant& excelInstance, Int32 launchMode, Boolean visible, Boolean loadAddInsAndMacros, Boolean needsAuthentication, Boolean readOnly, Boolean launchInNewInstance, String& version)\r\n at Microsoft.Flow.RPA.Desktop.Modules.Excel.Actions.LaunchExcel.Execute(ActionContext context)\r\n at Microsoft.Flow.RPA.Desktop.Robin.Engine.Execution.ActionRunner.Run(IActionStatement statement, Dictionary`2 inputArguments, Dictionary`2 outputArguments)\r\n"

  • Deenuji_Loganathan_ Profile Picture
    6,255 Moderator on at

    @Sivapriya 

    Could you please initiate a new topic for your question? This would be helpful for many individuals in the future

     

    Thanks,

    Deenu

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 664

#2
Haque Profile Picture

Haque 460

#3
Valantis Profile Picture

Valantis 357

Last 30 days Overall leaderboard