ALTERYX INSPIRE | Join us this May for for a multi-day virtual analytics + data science experience like no other! Register Now

Alteryx Designer Discussions

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

Running Powershell script in Designer

MatthewK
5 - Atom

Hi everyone,

 

I have a workflow that clones and fills in Excel templates with requests for another department. Said department takes PDFs, so I mashed together a Powershell script that converts the Excel files in a specified folder into PDFs:

 

MatthewK_3-1620157223537.png

 

The script works as intended when run manually outside of Alteryx, but I need this to run automatically within my workflow.

 

This is my current configuration: 

MatthewK_1-1620156892327.png

MatthewK_4-1620157954684.png

 

 

Depending on how I fiddle with the configuration, I have gotten everything from a blank Powershell window to error code 1.

Any help would be greatly appreciated, I'm stumped!

 

fmvizcaino
16 - Nebula
16 - Nebula

Hi @MatthewK ,

 

The configuration seems ok.

 

Were you able to run the ps1 file generated by Alteryx as well? 

 

One important detail related to the run command tool is that it doesn't work properly when using a non admin version of Alteryx designer.

https://community.alteryx.com/t5/Alteryx-Designer-Knowledge-Base/Installing-Admin-vs-Non-Admin/ta-p/...

 

Best,

Fernando Vizcaino

MatthewK
5 - Atom

Hi Fernando,

 

Tracking down the ps1 file Alteryx generated ended up being the clue I needed, thank you!

 

When I found & ran it, I realized Alteryx was not opening and running the generated script; specifying the working directory allowed the powershell script to run as expected. In this case, my workflow lives in a local Test folder.

 

Interestingly, I have a non-admin install, but am able to run command prompt and powershell scripts. Huh.

 

MatthewK_0-1620750095880.png

 

Labels