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 / Check to see if File N...
Power Automate
Answered

Check to see if File Name Already exists when creating a file in One Drive

(0) ShareShare
ReportReport
Posted on by 30

Hello all! I am trying to create a flow that, when a file is created, checks to see if a file by that name already exists and replaces it if it does. I am having trouble extracting the name when using the compose action. How can i extract the name so I can compare that to the list of files already in the folder? Thanks for all the help!

ArmoneyJ210_0-1711545913982.pngArmoneyJ210_1-1711545974844.png

 

Categories:
  • Verified answer
    marbaluv Profile Picture
    39 on at

    Hi @ArmoneyJ210 

    You can use this expression to retrieve the name of your file

    triggerOutputs()?['headers/x-ms-file-name']

    Currently you're using

    triggerOutputs()?['headers/x-ms-file-name-encoded']


  • ArmoneyJ210 Profile Picture
    30 on at

    Thanks for your help!

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 292 Super User 2026 Season 2

#2
Henil Profile Picture

Henil 128

#3
anirudhev Profile Picture

anirudhev 124

Last 30 days Overall leaderboard