Running Powershell script in Designer
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
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:
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:
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!
- Labels:
- Input
- Run Command
- Workflow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
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.
Best,
Fernando Vizcaino
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Can we run a PowerShell script that makes modifications to an Excel workbook on Alteryx Gallery/Server?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
The short answer is yes via the Run Command Tool, but it depends on how your Server/Gallery is set up to run. More info here under Default Run Mode - https://help.alteryx.com/20221/server/gallery
and details on the tools that are blocked depending on the Run Mode - https://help.alteryx.com/20221/server/safe-and-semi-safe-run-modes-blocked-tools-events-and-data-con...
