Start a workflow from the command prompt as a front Office robot



I have a batch file with this content: “C:\Program Files (x86)\UiPath Studio\UiRobot.exe” \file: “C:\Users\testrobot\Documents\UiPath\Projects\StartFromCmd\Main.xaml” The program will start the Robot exe, but the Main.xaml will not open. What can I do? Is there a solution to start the workflow?




Try to follow this guide and let me know if works.



@bozon, try this:
“C:\Program Files (x86)\UiPath Studio\UiRobot.exe” /file: “C:\Users\testrobot\Documents\UiPath\Projects\StartFromCmd\Main.xaml”

The “file:” argument must be preceded by a slash ("/"), not a backslash ("\"). It’s easy enough to miss even if you stare at it for a while … :slight_smile:

(This info is also in the link @Lucas.Pimenta provided)



thank you for your answer. I tried this before without any success. It was not a difference in the behavior. If I use a backslash, the Robot exe is starting, but not the Main.xaml file.

Mit freundlichen Grüßen/Best regards
Michael Boeckenhauer


Dear Lucas,

That’s the same syntax that I tried. The result is always: the Robot Exe starts the robot but not the workflow.



Have you checked if the workflow have errors? When we start a workflow through command prompt, if it fails, it’s doesn’t show anything on screen.

Try to execute from Uipath Studio and see if works.



Dear Lucas,

Yes, I tried this. The workflow is running fine from UI Path Studio.

Best regards,




Give a shot with the method mentioned by @acaciomelo on this another topic just to see if works.


Dear Lucas,

what a fantastic guide! Thanks alot. I tested it immediately. It works great!

Many thanks for the support, that helps me a lot.

best regards,



Deleted … Lucas answered it :slight_smile:


@ Lucas,


Could you please elaborate the steps again? What do you mean by “Create a shortcut using Run feature inside windows”?

I tried to create a shortcut for the windows “Run”, but I am unable to change the settings in “Properties” as it does not read it as a “.bat” shortcut, instead reads it as target Type “Run”



I also tried to rename the “Run” to “Run.bat”, still doesn’t work



try this:





Give a shot with the method mentioned by acaciomelo on this another topic just to see if works.
[]Scheduling a back office robot using task scheduler

Hi @mudit, Please try to follow the steps below: Create a .bat file like the one attached and set the parameters if necessary inside it Create a shortcut by using the Run feature inside windows Schedule it in Task Scheduler to execute this shortcut at certain moments and start your robot Both .bat file and the Run shortcut should be at the same folder of the robot. Run.zip (271 Bytes) [image] Copy it to your folder and change its properties like: [image] In task scheduler, just call it: …


Hello Michael,

My question is about this procedure itself.

When you say “Create a shortcut by using the Run feature in Windows”, what do you exactly mean.

I downloaded the zip file which has the “Run.bat”. Saved/Unzipped it in the path Downloads/Run

So now this folder has the file “Run.bat” which I edited and provided the paths that I needed to.

Now you say that I need to create a shortcut of “Run” and paste it in the same folder (Download/Run/). Did that. But on trying to edit the “Shortcuts” in “Properties”, it doesn’t allow me to edit it.

Target Type is mentioned as "Run…"
Looking at the screenshot, the target type should be Windows Batch file.

I tried to rename this to Run.bat but it still shows the same Target type.



Hello Amritesh,

try this: Scheduling a back office robot using task scheduler

Step by step and then open the windows Task Planning tool to configure the scheduled date and time, then link to your Batch file.

Kind regards,




You don’t need to create a shortcut of “Run.bat”. You just have to put it on the same folder as your Main.xaml workflow. Once it done, create a Task on Windows Task Scheduler and then set to execute the “Run.bat” as Action and your date/time as a Trigger.

Hope it Helps!