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

Community site session details

Session Id : SerQhLjqGDkJpaAFpXMFqg
Power Automate - Using Flows
Unanswered

Create a separate file while saving attachments

Like (0) ShareShare
ReportReport
Posted on 10 Jan 2022 18:53:30 by 10

Hello,

 

I have created a flow which saves a file from a particular mail every day successfully to my share point folder. However, the file is always replaced by the new file ( since all the files coming from this mail have the same name). I want them to be saved with a new file name instead of replacing the old file. e.g. the file come is abc.xls. The flow should save the file which comes the next day by the name abc1.xls and then the next day abc2.xls and so on instead of replacing the first file.

 

Note: I have already disabled versioning.

 

can anybody help me!!!

  • v-jefferni Profile Picture
    on 25 Jan 2022 at 02:33:22
    Re: Create a separate file while saving attachments

    Hi @AbhijitP ,

     

    You can create the variable for date just follow the trigger, use it in the create file action file name input area. But the point is you have to use the recurrent trigger to fire the flow once a day, then use get emails action to retrieve the latest email:

    vjefferni_0-1643078052585.png

     

    Hope this helps.

     

    Best regards,

    Community Support Team _ Jeffer Ni
    If this post helps, then please consider Accept it as the solution to help the other members find it.

  • AbhijitP Profile Picture
    10 on 24 Jan 2022 at 13:14:27
    Re: Create a separate file while saving attachments

    I tried this too but it did not halo the file is still being overwritten.

  • AbhijitP Profile Picture
    10 on 24 Jan 2022 at 13:13:13
    Re: Create a separate file while saving attachments

    Where do I put the Initialise variable so that it would be helpful to me??

  • v-jefferni Profile Picture
    on 13 Jan 2022 at 06:13:42
    Re: Create a separate file while saving attachments

    Hi @AbhijitP ,

     

    Since you will have the file stored in SP folder everyday (one file for one day I guess), you can also create a variable to store current date as text and format as "yyyyMMdd" and append the date along with the file name, so you could conveniently find the file in other days.

    vjefferni_0-1642054473666.png

     

    Hope this helps.

     

    Best regards,

    Community Support Team _ Jeffer Ni
    If this post helps, then please consider Accept it as the solution to help the other members find it.

  • jdoss Profile Picture
    458 on 12 Jan 2022 at 14:54:58
    Re: Create a separate file while saving attachments

    In that create file function instead of putting attachments name, put whatever you would like, since it is always the same you can use the guid(), see image. If you want to get the filename you can use the compose and a function to get the filename and attach a guid to it.name.png

  • AbhijitP Profile Picture
    10 on 12 Jan 2022 at 14:46:41
    Re: Create a separate file while saving attachments

    8F26DBFE-6B6B-4056-A247-F81A9D07FA64.jpeg

  • jdoss Profile Picture
    458 on 12 Jan 2022 at 14:46:13
    Re: Create a separate file while saving attachments

    What happens in the condition? Are you saving the file somewhere or just getting the attachment? 

  • AbhijitP Profile Picture
    10 on 12 Jan 2022 at 14:43:39
    Re: Create a separate file while saving attachments

    0B91A018-D386-4C42-92B9-ECDD8C31B409.jpeg

  • jdoss Profile Picture
    458 on 12 Jan 2022 at 14:31:13
    Re: Create a separate file while saving attachments

    Well you can use the option I mentioned, or what I typically do is use the guid() function and create a unique code. Just get the file name while parsing and change it and add the guid to the file name. More specifically the substring(guid(), 0, 😎 with the last number being how long you want the id to be. Without seeing that part of your flow it's hard to help.

  • AbhijitP Profile Picture
    10 on 12 Jan 2022 at 13:23:13
    Re: Create a separate file while saving attachments

    As I have mentioned, my file comes from the outlook and overwrites the existing file as the attachment in the mail always has the same name. What option should I try so that the file is not overwritten and new file is created with another name. Like abc1.xls and so on.

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 2

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 2

Featured topics

Restore a deleted flow
Loading complete