cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Rename File, But Keep Originator Email

I have a flow that takes a file from a drop off library and moves it to a "working" library. Before moving the file, I add a date/time stamp to the filename to ensure it doesn't overwrite an existing file that may have been created with the same filename.

 

I'm using the solution posted in this thread to "rename" the file by creating a new file with the new filename and inserting the contents of the previous file.

 

My problem now is that the flow that gets kicked off in the "working" library needs to be able to send an email back to the person who posted the original file. But since my other flow is creating a new file, it's setting the originator email to my email address.

 

How can I create a new file with the new name, but set its originator email to the originator of the initial file?

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: Rename File, But Keep Originator Email

Hi @Mark_Petereit,

 

Do you want to send an email back to the file originator?

It seems that you have created two flows, one flow is used to rename the file, another flow is used to send email to originator.

Please consider combining the two flows into one. I have made the following flow for your reference.

It is triggered by When a file is created (properties only).

Add a compose to return the originator by using dynamic content Created by email.

Add action Get file content.

Create file in a different library, input the following code into the File name field:

concat(utcNow('yyyy-MM-dd'),triggerBody()?['{FilenameWithExtension}'])

 Add action Send an email, select Compose Output for the To field.

A screenshot likes below:

1.PNG

Please take a try with it on your side. 

 

Best regards,

Mabel

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
Highlighted
Community Support
Community Support

Re: Rename File, But Keep Originator Email

Hi @Mark_Petereit,

 

Do you want to send an email back to the file originator?

It seems that you have created two flows, one flow is used to rename the file, another flow is used to send email to originator.

Please consider combining the two flows into one. I have made the following flow for your reference.

It is triggered by When a file is created (properties only).

Add a compose to return the originator by using dynamic content Created by email.

Add action Get file content.

Create file in a different library, input the following code into the File name field:

concat(utcNow('yyyy-MM-dd'),triggerBody()?['{FilenameWithExtension}'])

 Add action Send an email, select Compose Output for the To field.

A screenshot likes below:

1.PNG

Please take a try with it on your side. 

 

Best regards,

Mabel

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Top Solution Authors
Users online (7,417)