UiRobot run in Remote desktop

I can run my tasks in UiRobot inside the RDP. Here BOT run without orchestrator. Tasks are continue when I minimize RPD window. But when I close or disconnect RDP from my computer, the BOT do not continue its tasks and finally show a timeout exception and BOT is stops. How to continue BOT run in RDP when it disconnect from local machine.

In case of attended bot… it will not work when we disconnect from RDP. because bot will require windows active session.

Actually for both unattended and attended, when you disconnect your RDP session it interrupts UiRobot. So basically if you RPD into a session with a running process, don’t close it or it will stop it. If you would like it to run without you having an RDP session open, then start the job from Orchestrator while you are not in the RDP session and it will work. But as soon as you enter that logon session with RDP you can’t close it cause it stops the process… and I am not sure if there is a network configuration to change that.



Try to Invoke your workflows using ‘Launch Workflow Interactive’ activity, It works even when your are into an RDP session and your minimize the RDP. Not sure if there are any drawbacks of using it. I have seen it working in most of the case.

Let me know if it works for you as well.

Rammohan B.

Minimize RDP is working fine. I modify registry by https://robot.uipath.com/docs/executing-tasks-in-a-minimized-rdp-window. I need Robot continue its task after disconnect RDP from my computer. There is any solution to continue robot task without connect RDP from my computer

1 Like

Hi Linto Have you sorted out a solution for this scenario?

As far as I’m aware, there is no solution to keep a task from ending when you Disconnect an RDP window, but I could be wrong. Basically what happens is by Disconnecting your RDP, it puts the login session into a Disconnect state which interrupts the robot’s connection too.

However, technically there is a way to set up simultaneous logon sessions with the same user, which means if a Robot is running and you RDP, it will create another session and not interrupt that one. This method would cause too much of a headache though, because if a logon session is connected via Robot, you could never get into it to check/watch it or anything.

Thanks @ClaytonM for your reply. is that due to the version i am using. i am using commnity version. I just feel it is a bit of impossibe. what if i want to use multiple Robots in the remote desktop. I want to to work unattended. Does that mean I also need to turn on my computer to keep it work.

To avoid problems with GUI tests, use the tscon utility to disconnect from Remote Desktop.

To disconnect from Remote Desktop, run the following command on the remote computer (in the Remote Desktop window) as an Administrator:

%windir%\System32\tscon.exe RDP-Tcp# NNN /dest:console

You can run your Robots unattended just as long as you close your RDP connection prior to starting a job on that session. And if you RDP while it is still running, just don’t close it, rather put it in the background on your computer so you don’t interfere. I think most companies that have a pool of Production Robots are not giving access to them to the developers; while it does restrict the devs and makes it a little annoying to have to rely on one person to fix issues in the user profile, it does avoid instances where someone RDPs into a session that is running a job.

Cool. I’ll have to try that some time.

Hi Linto
After I run “%windir%\System32\tscon.exe RDP-Tcp# NNN /dest:console” from CMD as an administrator in the remote desktop window, i get the below message.

"Invalid parameter(s)
Attaches a user session to a remote desktop session.

TSCON {sessionid | sessionname} [/DEST:sessionname]
_ [/PASSWORD:pw | /PASSWORD:*] [/V]_

_ sessionid The ID of the session._
_ sessionname The name of the session._
_ /DEST:sessionname Connect the session to destination sessionname._
_ /PASSWORD:pw Password of user owning identified session._
_ /V Displays information about the actions performed."_

Do you encounter the same error message?

This command used for disconnect RDP. By use this command then current user move to console state.
Follow below steps:
You can automate the disconnection procedure using a batch file. On the remote computer, do the following:

  • Create a batch file with this code:

for /f “skip=1 tokens=3” %%s in (‘query user %USERNAME%’) do (
%windir%\System32\tscon.exe %%s /dest:console

  • Create a desktop shortcut to this file. To do this, right-click the batch file and select Send to | Desktop (create shortcut).
  • In the shortcut properties, click Advanced and select Run as administrator .

Run the robot and execute the batch file



That makes sense, but then I guess it is not very much desirable that the RDP session needs to be connected all the time(even for unattended bots) .bcoz that is not feasible in the real time scenario.

Please suggest.


hello I’m doing some tests moving a robot to a remote desktop, the robot opens the browser enters a page x, download a report, but when I try to call from orchestator gives me an error
error only gives me when I do not have the open session of the remote deskopt, but I have another test robot that writes a date log in a txt and that works for me.