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

copy file when new one uploaded or modified

 

I have used a template to create a flow to copy documents uploaded, created or modified in a library in one site into another sharepoint library within the same site.  I don't know how frequently it runs, but nothing appears to be happening at the moment. When I click Test and upload a file it also does not run.

Can anyone help to identify what I have missed out or entered incorrectly.

Many thanks

 

flowtest.png

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Regular Visitor

Re: copy file when new one uploaded or modified

After a lot of playing around, I managed to sort it!  Always user error in the end and it now does exactly what it is being told.  Be careful of the placement of the / as it is not included in the first site address, but it included in the 2nd site address

flowresult.png

View solution in original post

6 REPLIES 6
Highlighted
Dual Super User
Dual Super User

Re: copy file when new one uploaded or modified

Hi!

THe trigger is 'When a file is created', so your flow runs everytime you upload a new file to the site & folder you selected:

/Shared Documents/Forms

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Highlighted
Regular Visitor

Re: copy file when new one uploaded or modified

Thank you for your reply.

  • In both libraries I do not have any folders, so is the path correct?
  • And if I upload a pdf to the library at the top, should it copy to the other library in the second box?
  • How long does it normally take?

Many thanks

Highlighted
Dual Super User
Dual Super User

Re: copy file when new one uploaded or modified

Hi!

My suggestion is to create the folders -at least the source folder, where the trigger is checking- and then upload a file for testing purposes. In my case, it takes no more than 3 minutes

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Highlighted
Regular Visitor

Re: copy file when new one uploaded or modified

@efialttes Do I need a folder? I was trying to avoid creating folders in line with guidance on minimising folders in SharePoint and I don't really need a folder in this library

Can I move files that in the top level of the document library?

Many thanks

Highlighted
Dual Super User
Dual Super User

Re: copy file when new one uploaded or modified

Hi!

According to the official documentation there are at least two triggers you can use:

 

When a file is created (properties only)

Triggers when an item is created in a library. Returns only the properties stored in the library columns. You can add a "Get file content" step and use the "File identifier" property returned by this action to get to the contents of the file. When using this with the On-Premises Data Gateway, the name of the library to connect to may need to be entered manually.

When a file is created in a folder

Triggers when a file is created in a SharePoint folder. The trigger does not fire if a file is added/updated in a subfolder. If it is required to trigger on subfolders, multiple triggers should be created.

 

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Highlighted
Regular Visitor

Re: copy file when new one uploaded or modified

After a lot of playing around, I managed to sort it!  Always user error in the end and it now does exactly what it is being told.  Be careful of the placement of the / as it is not included in the first site address, but it included in the 2nd site address

flowresult.png

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 (8,051)