cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
rhawkins10701
Helper I
Helper I

Rename multiple downloaded files from web then move to specific folder

Related to issue: Using Excel data to populate web text field 

@VJR 

I think I understand the variables a lot better now and how to use it. I really appreciate the help with this! I have another variable that I am going to add which is %FileName%. Once, all the actions are completed and file is downloaded. File will be in download folder and file needs to be renamed and moved to particular destination. Then loop back through the same actions for all other JRPB account numbers to download, rename file, and move file. Until there is no more JRPB accounts to download.

 

The actions I took: 

 

- Created new list %FileName%

rhawkins10701_0-1636213946999.png

 

 

- Then under the 1st nested action I use Add item to list action CurrentItem ['File Name'] to list %FileName%

(I had to keep space in order for PAD to read column name and it worked!) 

rhawkins10701_1-1636213946941.png

 

 

See example of data below.

 

Client CodeAccount NumberFile Name
JRPB1234ABCD
JRPB5678EFGH
JRPB1111IJKL
JRPB2222MNOP

 

Currently the first account number and file is renamed and moved to folder. Which is perfect! When actions loop back around for the second account number (5678) file is named ABCD again and doesn't move to designated folder since file name is already there. See actions below. 

 

- I created another for each action for each file name. But currently when it runs, it doesn't go to the next file name on list.

 

rhawkins10701_2-1636213946911.png

 

 

 

I need account number 5678 when selected to name file EFGH.  Need each file to be renamed from the corresponding account number that was downloaded. I did an exit loop because I didn't want it to loop until the first actions to download file is done. 

1 REPLY 1
VJR
Super User
Super User

Hi @rhawkins10701 

 

The Exit loop is causing the problem of picking up the first file name every time.

You need to remove the exit loop.

 

All your actions (download, rename file, and move file) will need to be inside this loop.

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Super User 2 - 2022 Congratulations 768x460.png

Welcome Super Users

The Super User program for 2022- Season 2 has kicked off!

Top Solution Authors
Top Kudoed Authors
Users online (3,579)