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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to rename a file i...
Power Automate
Unanswered

How to rename a file in one drive that comes from a zip file?

(0) ShareShare
ReportReport
Posted on by 16

I have created a flow to save an excel file to OneDrive, that comes attached in an email in zip format.
The zip includes an excel file whose name includes the date of shipment and a different code each week: email attachment > weekly_report.zip > weekly_report_14_08_2023_1692026614486_Report.xlsx

It works but now I need to rename it as 'weekly_report', so that it overwrites every time the flow works. Can you help me?Screenshot 2023-08-16 172238.jpg

Categories:
I have the same question (0)
  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Krodriguez1 

     

     

    Consider using the two below action steps. First find the files in that particular folder. Then use move or rename a file action step.

    image.png

  • Krodriguez1 Profile Picture
    16 on at

    Hi @abm 

    I have added the 2 steps you shared with me, but the last step fails and I get this error detail: "The resource could not be found" (Status code 404).

    run1.jpg

  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Krodriguez1 

     

    Are you trying to rename the file  weekly_report_14_08_2023_1692026614486_Report.xlsx to weekly_report?

     

    Thanks

  • Krodriguez1 Profile Picture
    16 on at

    Hi @abm 

    Yes, that's right.
    This morning I received the zip file with last week's excel report 'weekly_report_21_08_2023_1892027714536_Report.xlsx'

    what I need is that every time I extract the excel file from the zip, rename it, to use the path for other reports and avoid accumulating different files. is it possible?

  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Krodriguez1 

     

    I need to see your mapping for the above. I did tried the below and worked.

     

    image.png

  • Krodriguez1 Profile Picture
    16 on at

    Hi @abm I think, the problem is that my Excel file each week has a different name. Here is my flow
    pA.jpg

  • abm abm Profile Picture
    32,865 Most Valuable Professional on at

    Hi @Krodriguez1 

     

    You may need two flow. One to extract archive to folder.

     

    Is this path going to be same?

     

    image.png

     

    Create another flow (Second one) when a file is created under that directory. Make sure put an If condition to check filename contains Report.xlsx or something. Then do the rename part.

     

    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

Forum hierarchy changes are complete!

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

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 525 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 324 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard