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 to set "File Name"...
Power Automate
Answered

How to set "File Name" property on "Create File" SharePoint action dynamically

(0) ShareShare
ReportReport
Posted on by

Hello,

I have created a flow with a CDS trigger When a record is selected. In this trigger I have a user input of type File. Below the trigger I have a SharePoint action to Create File.

 

I need to set the File Name property of Create File action to the file name of the file that user would select. I tried Dynamic Content pane but no luck.  Can we have any workaround to get this done?

 

Flow to upload SharePoint document.jpg

Categories:
  • DeepakS Profile Picture
    2,301 Most Valuable Professional on at

    HI @KAL 

     

    To get the file name you can add a text input and ask user to add file name. 

    here is an example:

    CDS.png

     

    -----------------------------------------------------------------------------------

    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.

     

  • Verified answer
    abm abm Profile Picture
    33,004 Most Valuable Professional on at

    Hi @KAL 

     

    You can get the filename using the below expression

    triggerBody()['file']['name']
     
    For the file content you need the following
    triggerBody()['file']['contentBytes']

     

    image.png

     

    Here is my run result

     

    image.png

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

These are the community rock stars!

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 231 Super User 2026 Season 2

#2
David_MA Profile Picture

David_MA 217 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 170

Last 30 days Overall leaderboard