Hi, I am using Start Process activity to run a cmd file that launches my java application. When I run it from UiPath Studio, it works fine. When I login to the machine and run it from Orchestrator, it works fine as well. However, when I log off from the machine, the automation fails as it cannot find the uielement.
I have tried looking for the process. In the unattended automation run from Orchestrator (with machine not logged in), I can see that the process does exists, but there is no window handle.
The machine is a virtual machine, running on Windows 10.
Any idea what else I can try? Ideally, I do not want to be logging into the machine to run the automation. For the Robot settings, I have already set the user credentials and set Login to Console as false.
Did you try running it without logging in to the machine? That’s the way unattended robots are supposed to worked, you shouldn’t interfere with the robot session.
Are you just closing the RDP window or are you actually signing out?
Sounds like Robot is installed in user mode, not service mode. For unattended automations it has to be installed in service mode. Reinstall and select service mode.
If bot is working fine in attended mode it will work in unattended mode as well
So it’s about the installation
Basically to understand the difference in mode of installation
Service Mode - recommended for unattended automation scenarios and large-scale platform deployments, and runs with the same rights as the user under which it is registered.
User Mode - recommended for attended automation scenarios, and runs under the user that installed it, having the exact rights as that particular user.
So check once whether it is installed in service or user mode
would recommend to check if you see below service in services tab of task manager
Start → task manager → services
UiPath.Service.host - this comes only for service host
UiPath.Service.Userhost - this will be there for user mode…
The services running isn’t what you need, there are still services when you’re in user mode. When you are installing Robot on the server, there is a checkbox to tell it to run as a service. Re-run the installer and check this box.
I have tried re-running the installer again and also checked that it is in service mode:
*Note: when I run the installer, the install robot as windows service was already checked.
Before trying again, I had to reboot my VDI due to some issues (was stuck at logging out actions), and then the unattended automation started to work again! So… totally no idea what happened
I try to rerun the installer, reboot VDI, but still unable to get the java application window working. When I saw that it was “stuck”, I paused the job and remote into the machine, and could see the process running, but no window.
But do you know that when it was originally installed, that box was checked? Just go ahead and reinstall in service mode so you know it’s installed in service mode.