web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Flow renames file only...
Power Automate
Unanswered

Flow renames file only once and then replaces them

(0) ShareShare
ReportReport
Posted on by 14

Hi,

 

I have below from which downloads attachment (picture) from email and saves it to folder on One Drive. Because I already have the same filename there, before saving, I rename the old picture and add timestamp to it, then save it to the same directory. This happens OK for the first time.

 

 

concat('/Email attachments/','filenamehere',utcNow(),'.png')

 

 

 

But next time the flow rename the original picture from email but instead of renaming it to a new file, it replaces the old rename file which already had timestamp.

 So it keep adding new files because the timestamp is different than the file renamed 5 minutes ago.

flowerorr.jpg

Hope it's clear.

Thanks.

K.

 

EDIT:

I understand it like when I am selecting the file to rename in the flow I have to select specific file to which the workflow probably assigns a hash code and stick with it no matter the filename. I will try to put there expression instead of specific file.

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

    HI @jakub_ 

     

    Try doing everything in one step. In the create file, you can add the name you want to the file so that you can rename it with the timestamp directly. No need to move since all files you create are unique.

     

    Also, instead of a timestamp, you can add a random number to ensure that you always have a unique file.

     

    Makes sense?

     

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

  • jakub_ Profile Picture
    14 on at

    I can try it but as I understand it I would not have a file without timestamp. The file is a picture and this picture is linked to a PP presentation so if I don't keep the latest file with filename without timestamp the link to PP will not work.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
trice602 Profile Picture

trice602 237 Super User 2026 Season 1

#2
David_MA Profile Picture

David_MA 176 Super User 2026 Season 1

#3
Power Platform 1919 Profile Picture

Power Platform 1919 96 Super User 2026 Season 1

Last 30 days Overall leaderboard