I need help with an issue I am facing in the Production Orchestrator. When I run the bot in unattended mode, I get the following error after some time: “The bot started running and then this error appears” (screenshot attached). Could you please help me understand what all things I need to check from the Orchestrator side and from Studio? This will help me resolve the issue in Production.
@Snehamayi_Senapati Secondly try to bring the target element in forground using scroll activity as some time robot cant able to identify or highlight the target element
Then try with the second approach which I suggested check the selector and make sure there is no message box are there on your code and check unattended license are assigned or not
Is the robot installed in user mode or service mode? ideally it should be in service mode
Properly signout the user from the VM.not disconnect but signout. disconnect will leave the user session and session cannot be taken by robot
Make sure no pops are present like windows updates or so..they would block the application and you might see this error. disable any windows pop ups..check screenshot if you can find any issues like that
As per error windows session is locked are you trying to start the bot and close or disconnect the machine or minimize it?
@Snehamayi_Senapati Some times but is unable to identify the element event if we have provided simulate its happens with me too so try to bring the element in forground and also check weather the given setting are also applied for your robot
Hi @Snehamayi_Senapati .
The error “Cannot bring the target application in foreground because the session is locked” means the unattended robot is trying to perform UI actions while the VM is locked / RDP disconnected.
What to check in Orchestrator
Unattended robot credentials
Confirm correct Windows username + password.
Machine/Robot status
Machine must be Connected & Licensed.
Resolution settings
Set Resolution: 1920×1080, Depth 32.
Runtime availability
Ensure your folder has a free Unattended runtime.
What to check on the VM
No one should be logged in via RDP.
Sign Out, do NOT Disconnect.
Disable lock/sleep/screensaver settings.
What to check in Studio
Use Simulate Click/Type wherever possible.
If the XAML uses activities like Activate Window / Click, they will fail if session is locked — redesign to avoid foreground dependency.
Quick Fix
Sign OUT of VM → not disconnect.
Re-enter correct credentials in Orchestrator → Unattended Robot.