I am new to Microsoft Flow and don't have a programming / developer background. I have a SharePoint Online library which is getting a file copied using Content Organizer Rules. What I want to do is simply rename the file using the metadata the file already has.
The file comes over like this: 20190120000020B269FDocument1.pdf
Every file has the following metadata: Title, First Name, Last Name, Full Name, Date Recieved
What I'd like to do is rename the file to Title - Date Recieved.pdf .
I would like to know what steps I'll need to accomplish this. I can't seem to find a SharePoint Rename action.....
Any help is much appreciated!
please flow the following steps to update the file meta data.
However if you want to rename the file name you have to create a copy of file and remove previous one.
After creating file just delete the old one.
If you find this helpful Please mark it as a Solution.
Harry_G have provided a complete solition.
I have made a flow for your scenario, please check it for a reference.
Please feel free post back if you need more help.
It took me a while to get back to this. I'm trying to add images of my flow here but I'm not sure how to do that.
I have three attachments....can you please advise me on how to add them to this particular thread?
goto Reply -> Click on Photo Icon -> Choose File -> click on Done .
PLease see images below;
If this Answer is helpful, please mark it as a solution. So other will find it helpful.
Here is what I have created for our library. What I want to do is basically: when a file is created in the folder, check the file name, if it is in the right format, then do nothing. Otherwise, change the name using the metadata but keep the file in place. Here is my concat line info: concat(variables('varTitle'),'-',variables('varDateRecieved'))
My flow gives me an error saying "Actions in this flow may result in an infinite trigger loop. Please ensure you add appropriate conditional checks to prevent this flow from triggering itself."
I also tried using the "When a file is created or modified (properties only) trigger.
When I test this, it does not do anything. I am at a loss. Help! Please
Thanks in advance!
I think issue occured due to triggering flow on creation of file. Your flow also have a action which creates file so flow will start automatically again and again. however in next run your flow not creates the new file if name matches the format but May be there is any kind of check by MS for this scenario. Kindly check your flow by deleting the create file action and check the error, is still occured or not?
I don't think I really understand the purpose of deleting my create file action? How would deleting that actually be helpful to me? The purpose of my flow is to essentially rename a file and keep all existing metadata and file properties except for the name. I only want to have this triggered when a file is created in the library that doesn't follow the given format. Then I want to delete the original named file so I don't have two files (and keep the correctly named file).
I think you may find this article helpful.
I've used it to rename a file - creating a copy and deleting it is not a great idea if you want to retain version histories.
Join us for the first ever Power Platform Online Conference!
Look out for new contribution recognition badges coming SOON!
We've updated and improved the layout and uploading format of the Power Automate Cookbook!
Fill out a quick form to claim your user group badge now!
Find out where you can attend!
Watch & learn from the Power Automate Community Video Gallery!