Alteryx Designer Desktop Discussions

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

alteryx api for vb.net , run workflows with vb.net application

soumyarani
5 - Atom

have a licenced copy of alteryx and want to run some workflows using a vb.net application, researching the alteryx comunity found that this is posible using an api but it is for c++ need for vb.net, anyone has some examples I could refer to and the corresponding api to use with? thanks a lot

4 REPLIES 4
joshuaburkhow
ACE Emeritus
ACE Emeritus

@jdunkerley79 @tlarsen7572 - Is this something one of you two have dived into? 

 

@StephV This post might be better in the dev boards? 

Joshua Burkhow - Alteryx Ace | Global Alteryx Architect @PwC | Blogger @ AlterTricks
jdunkerley79
ACE Emeritus
ACE Emeritus

Yes I have used the Automation API. I'll dig out some C# code for doing it and post

jdunkerley79
ACE Emeritus
ACE Emeritus

You need references to:

  • AlteryxAPI.Net.dll
  • AlteryxDocument.dll

 

Have found I need to do:

var alteryxInstall = Alteryx.AlteryxApi.GetAlteryxInstallDir();
Console.WriteLine($"Added to run time PATH: {alteryxInstall}");
string pathvar = System.Environment.GetEnvironmentVariable("PATH");
var value = pathvar + alteryxInstall;
System.Environment.SetEnvironmentVariable("PATH", value, System.EnvironmentVariableTarget.Process);

 This sets up the environment variables to know where Alteryx is.

 

To run a yxwz file:

var aWizard = new Wizard(fileName);

var wizardParams = aWizard.CreateParameters();
foreach (var qp in values)
    wizardParams.Add(qp.Key, qp.Value);

aWizard.Message += (sender, e) => Console.WriteLine($"{DateTime.Now:HH:mm:ss} - {e.Status}: {e.Message}");
aWizard.Run(RunnableDocument.RunMode.OutOfProcess, wizardParams, "", userData);

 

Please note you need a server licence for any of this to work!

kavyasahu
5 - Atom

have a licenced copy of alteryx and want to run some workflows using a vbnet  application, researching the alteryx course  comunity found that this is posible using an api but it is for C need for vb net , anyone has some examples I could refer to and the corresponding api to use with? thanks a lot

 

 

 

 

 

Thanks.

mobelaris 

 

 

 

Labels