Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

How to get a flow to download a PDF to the user’s own OneDrive?

(0) ShareShare
ReportReport
Posted on by 29

Hi All

 

I built a flow that downloads a PDF to my downloads folder in OneDrive. This was designed to be used by the whole team but when other team members execute the flow. It sends the PDF into my personal OneDrive and not theirs.

The flow connections are using my login authenticate and I tried changing it to use the team’s distribution email.

 

Q: Is there a way to get the flow to save the PDFs to the OneDrive of the person who executes it?

  • HenryAtCQC Profile Picture
    29 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    Thanks, @MarkBandR 

     

    Thanks for investigating the "On Power BI button clicked" trigger and it’s a shame that it doesn’t have the "Provided by run-only user" as an option.

     

    I changed the flow to save the PDFs output to a shared SharePoint folder that’s working.

    I will run the idea of saving PDF as an e-mail attachment to my team.

     

    Thanks 

  • MarkRahn Profile Picture
    1,059 Super User 2025 Season 1 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    Hi @HenryAtCQC 

     

    I created a similar Flow:

    MarkBandR_0-1697041229564.png

    Here is where "Run only user" would show up

    MarkBandR_2-1697042249014.png

    But I duplicated the basic part of your flow, and Power Automate is only allowing the "Connections Used" to be fixed on my account as the Owner of the Flow. I don't think the "On Power BI button clicked" trigger has the same "awareness" as the "For a Selected File" trigger for SharePoint.

    MarkBandR_3-1697042530066.png

    I'm not sure you are going to be able to get what you want. You may need to switch tactics and email the generated pdf to the user (because the "On Power Bi button clicked" trigger does capture the email for the user that clicked the button).

     

    Sorry I couldn't be more help.

     

    -Mark

     

  • HenryAtCQC Profile Picture
    29 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    My flow export an embedded paginated report in Power BI using the Power Automate visual.

     

    Major actions

    Trigger:     On Power BI button clicked

    Next Step: Export To File for Paginated Reports 

    last:           Create file in OneDrive

     

    HenryAtCQC_0-1697040964269.png

     

  • MarkRahn Profile Picture
    1,059 Super User 2025 Season 1 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    Hi @HenryAtCQC 

     

    What trigger are you using to start the flow? For the example I did I was using "For a selected file" from the SharePoint Actions. That might be what is limiting what you see on the Details page.

     

    -Mark

  • HenryAtCQC Profile Picture
    29 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    No, I still don't have access to "Provided by run-only user" from the "Connections Used". It only shows my work email. I am looking around for how to enable this

  • MarkRahn Profile Picture
    1,059 Super User 2025 Season 1 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    Hi @HenryAtCQC 

     

    Were you able to get things working?

     

    -Mark

  • HenryAtCQC Profile Picture
    29 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    I don't seem to have this option.  Is it a new feature?

  • Verified answer
    MarkRahn Profile Picture
    1,059 Super User 2025 Season 1 on at
    Re: How to get a flow to download a PDF to the user’s own OneDrive?

    Hi @HenryAtCQC ,

     

    The flow needs to be set up to so that the "Connections Used" are set to "Provided by run-only user". To do this, go to the Details View of the Flow. Look for "Run only users" to the bottom right:

    MarkBandR_0-1697022377308.png

    Click on Edit. (For the test I did I was using a SharePoint Document Library).

    Check that the "Connections Used" are set to "Provided by run-only user".

    MarkBandR_2-1697022475895.png

    When a user other than yourself runs the flow, it should save to their personal One Drive.

     

    -Mark

    If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.

     

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

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard >