HI,
I have a SharePoint folder(Original Files) which has around ~49 excel files(this count may change every week) and i have another folder named (Distributed Files) and with in that i have 5 sub folders A, B, C, D and E.
I am trying to automate this to distribute the files in SharePoint folder(Original Files) to the 5 sub folders A, B, C, D and E in (Distributed Files) equally.
Example:
SharePoint folder(Original Files) - 49 files.
SharePoint folder(Distributed Files):
A - 10 files
B - 10 files
C - 10 files
D- 10 files
E - 9 files.
Thanks.
Hi @PowerMani ,
Refer to following process
For remaining part of files, divide them into chunks and repeat the "Apply to each" to move files by order.
Here are functions to group them into groups of 10:
take(outputs('Get_files_(properties_only)')?['body/value'],10)
skip(take(outputs('Get_files_(properties_only)')?['body/value'],20),10)
skip(take(outputs('Get_files_(properties_only)')?['body/value'], 20), 10)
skip(take(outputs('Get_files_(properties_only)')?['body/value'], 40), 30)
skip(outputs('Get_files_(properties_only)')?['body/value'],40)
Community Support Team _ Wenjuan Zou
If this post helps, then please consider Accept it as the solution to help the other members find it.