In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests Early 2026. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Running an Excel Macro Using the Command Tool in Alteryx

Sonalik10
5 - Atom

When I try to use the command tool to run my excel macro found in my excel sheet I am getting an error that I need an output. When I put an output I get another error stating that the "external program "cscript" returned an error code:1 "

 I followed this video step by step but am still seeing problems. 

https://www.youtube.com/watch?v=k3RqxUc25ig 

 

Sonalik10_0-1656532982901.png

Sonalik10_1-1656533024530.png

Sonalik10_2-1656533376243.png

 

In this Data in the Wild episode, we'll show you How to Run Excel Macro Using Alteryx Designer. If you have any questions or suggestions for a future video, leave a comment below! Ready to try out Alteryx? Get a 30-day Free Trial: ...
3 REPLIES 3
markcurry
12 - Quasar

Hi @Sonalik10 

 

If you click on the 'Input..' button, is the file format set to a CSV file, and do you see the .vbs code?  

 

markcurry_0-1656535921168.png

 

I see from the screenshot that you have "\VBA_Example.vbs" as the argument.  This would mean that is' expecting the VBScript file to be in C:\VBA_Example.vbs , so if you remove the \ , it should expect it in the same location as the workflow.

 

I've a attached a version of the workflow, so hopefully that works for you, if the above suggestions don't.  Hope that helps.,

 

KilianL
Alteryx Alumni (Retired)

You can also compare your setup with this knowledge base article: https://community.alteryx.com/t5/Alteryx-Designer-Knowledge-Base/Alteryx-Run-Command-Executing-Excel...

RolandSchubert
16 - Nebula
16 - Nebula

Hi @Sonalik10 ,

 

I think, adding an output file to the Run Command tool should solve your problem. You could e.g. add something like "temp.yxdb" as output (Write Source). I've used this logic in some workflows, it seems, a kind of dummy output file is needed.

 

Best,

 

Roland

Labels
Top Solution Authors