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 / How can store failed d...
Power Automate
Unanswered

How can store failed desktop flow error within cloud flow ?

(0) ShareShare
ReportReport
Posted on by 73

Hello,

In my use case, I'm running calling desktop flow (by action 'Run a flow built with the power Automate for Desktop') from the cloud flow. For any reason the desktop flow is failing and returns the output body details with error.

 

Niraj466_0-1680872079250.png

I want to catch and store the error message occurred from Desktop flow action. In 'Compose' action set as 'Configure run after as 'has failed', looking at the Dynamic content, I'm NOT seeing the body variable of the run desktop flow action.

Niraj466_1-1680872302807.png

 

 

[We see the body variable if it is the cloud flow called as child flow, but not the desktop flow.]

 

How can I store this error message that I can use to send either through email or store somewhere else?

Categories:
I have the same question (0)
  • Sundeep_Malik Profile Picture
    6,484 on at

    Hey @Niraj466 

     

    You can follow my below technique to log errors in sharepoint or in any database:

     

    Logging of Actions in Sharepoint. [Inputs, Outputs, Final Status, Start Time, End Time], Log Errors. 

     

    I hope this helps 🙂

  • Nived_Nambiar Profile Picture
    18,136 Super User 2026 Season 1 on at

    Hi @Niraj466 

     

    For getting the output body from run desktop flow action, you can use the outputs function

    outputs(action_name) , where the action name you have to pass in to the function.

    Here i have use the below flow

    Nived_Nambiar_0-1680878052820.png

     

    Here i have made one compose to run when desktop flow is failed , other compose action to run when desktop flow is success. 

     

    In the compose Failed, i have used the below expression:

    outputs('Run_a_flow_built_with_Power_Automate_for_desktop')?['body']?['error']?['code']

     

    This will capture the error code, you can change the code to message if you want error message.

     

    Hope this helps 🙂

    Mark it as solution if it resolves your query 🙂

  • adbryson Profile Picture
    23 on at

    Thanks @Nived_Nambiar , just what I was looking for!  And thanks for a quick and to the point answer!

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!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 103 Super User 2026 Season 1

#2
Haque Profile Picture

Haque 87

#3
trice602 Profile Picture

trice602 63 Super User 2026 Season 1

Last 30 days Overall leaderboard