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 / Passing Values From Po...
Power Automate
Answered

Passing Values From Power Automate to Desktop Flow via Text File

(0) ShareShare
ReportReport
Posted on by

I have a cloud flow that calls a desktop flow to which I need to pass three text values.  Since OneDrive is accessible to both, I'm using the Create File action to create a .txt file in OneDrive with one value per line.  The text file is created successfully and looks fine. In Desktop, the Get file content step is only retrieving "Byte [50]".  

Ukiman1014_0-1689370181214.png

When I look at Get file content's documentation, it says the output is binary. How can I simply read the text from the file, splitting each line into a variable?  Again, this is a text file in OneDrive, it is not local.

Is there a better way to pass text values from cloud to desktop flows?

  • Verified answer
    Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    Yes, there is. Use Input variables in the desktop flow. They can be added here:

    Agnius_0-1689395394029.png

     

    Add an input variable of type text and then, when launching the desktop flow from the cloud flow, the Run a flow built with Power Automate for desktop action will ask you to provide values for the input variables. You can add as many as you want.

    -------------------------------------------------------------------------
    If I have answered your question, please mark it as the preferred solution.
    If you like my response, please give it a Thumbs Up.

    If you are interested in Power Automate, you might want to follow me on LinkedIn at https://www.linkedin.com/in/agnius-bartninkas/

  • Ukiman1014 Profile Picture
    on at

    Thank you!  I then struggled a bit with getting variables that I passed to the desktop flow into and back from PowerShell.  I learned that I can pass multiple variables into PowerShell, but only get one out.  Well, there's the main output variable and then another one containing any errors.

  • Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    Yes, the Run PowerShell script action only supports returning a single variable as output. You can return a JSON blob though and convert it to an object in PAD using the Convert JSON to custom object action, if you want several output values.

    -------------------------------------------------------------------------
    If I have answered your question, please mark it as the preferred solution. If you like my response, please give it a Thumbs Up.

    I also provide paid consultancy and development services using Power Automate. If you're interested, DM me and we can discuss it.

     

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

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 237 Super User 2026 Season 2

#2
David_MA Profile Picture

David_MA 227 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 194

Last 30 days Overall leaderboard