You can use the Get Files action and in the Advanced section it will have an option to Sort by the modified date and choose the Descending switch as per your requirement.
This will give a Datatable called Files. Loop through the Files datatable for 10 times as you copy/move the files.
Follow the pseudo logic.
-Set variable counter =1
-Get files in folder
-for each loop on %files%
If counter<=10 then
Copy files (make sure here you use current item and not %Files% as you have used which is causing everything to get copied)
Increase variable counter by 1
-end of for each loop
Be noted in your code Counter starts from 1 and the "IF" condition is <=10 which means 0 to 10. It will process 11 documents.
Counter = 1
If Counter <=10
Counter = 0
If Counter <10
Keep up to date with current events and community announcements in the Power Automate community.
A great place where you can stay up to date with community calls and interact with the speakers.
Check out the latest Community Blog from the community!