Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Reading multiple excel files with passwords

davidogundipe
8 - Asteroid

Hey, 

 

I'm trying to compare multiple excel spreadsheets to one another. In order to open up the spreadsheets, I need to use the directory tool because they're password protected. Is there a way to open multiple password-protected files from the directory and inputting their passwords? I found a solution on this issue when there's one file. The solution used R and it worked fine, but I'm not sure how to do this with multiple files? Please let me know if you can help. 

 

Update:

I've attached a workflow below of me opening one password protected file "mock batch payment February". The password is "Password4". However, this doesn't even seem to be opening anymore. I keep getting a WriteYXDBStreaming() error on the R code. Please let me know if you can help me with these issues.

 

 

11 REPLIES 11
Harbinger
9 - Comet

@davidogundipe are the passwords different?

davidogundipe
8 - Asteroid

Yes, they are. 

Harbinger
9 - Comet

@davidogundipe Cool, they're the same; there are ways to do this if they are not but this makes it easier.

 

You'll need to iterate that R solution.

 

I have attached my solution here. In essence, we take the file and password and pass it multiple times to the R code. 

 

You can just loop in R as well, but this is the alteryx community so figured I'd do it within this tool's capabilities. 

 

That iteration is found in that final tool here, an iterative macro. I attached the packaged workflow so you can just take the macro from there! 

 

Harbinger_0-1602789920445.png

 

davidogundipe
8 - Asteroid

Hey, thanks for the help. However, the passwords for the files will be different. Could you show me how to do this with passwords that are different. 

Harbinger
9 - Comet

🤦‍ hahaha I forgot what question I asked, give me 5. 

davidogundipe
8 - Asteroid

No problem thanks! And do you mind also sending the ymxc macro file as well? Alteryx is telling me that it's missing.

Harbinger
9 - Comet

OK open this application within Alteryx. 

 

Pass filenames and passwords as comma separated couplets, one per line like this 

Book1.xlsx, hellobook1
New Microsoft Excel Worksheet.xlsx, hello

 

The new workflow should have the macro but I have added that here for good measure. 

 

Harbinger_0-1602792342855.png

 

davidogundipe
8 - Asteroid

Sorry, I'm very new to alteryx.  Which tool should I add the files and passwords in? And should I put the directory tool after the input tool? I noticed that the directory tool isn't in the ymxc file you sent.

Harbinger
9 - Comet

@davidogundipe if you open the attached packaged workflow, you should only have to change where the directory tool is looking for your files! 

Labels