Your agent's clicks stop when you minimize Remote Desktop or lock the screen
Description and use
GUI automation agents fail when an RDP session is minimized, disconnected, or locked because Windows stops drawing the desktop. Fixes include setting RemoteDesktop_SuppressWhenMinimized, using tscon to return the session to the console, or switching to VNC to keep the desktop active.
Problem
GUI automation agents fail when the Remote Desktop session is minimized, disconnected, or locked, because Windows stops drawing the desktop and synthetic input has no target.
Outcome
Agents resume reliable operation when the desktop remains active, eliminating failures caused by minimized or locked RDP sessions.
Workflow
- 1. Identify if the RDP session is minimized, disconnected, or locked.
- 2. If minimized, set the registry key RemoteDesktop_SuppressWhenMinimized=2 on the local machine (HKCU or HKLM).
- 3. If disconnecting, run the tscon command on the remote machine to return the session to the console without locking.
- 4. Alternatively, use a VNC server that preserves the console desktop.
- 5. Verify the desktop remains unlocked and drawn before running the agent.
- 6. Monitor for idle lock or sleep timeouts and adjust settings to prevent mid-run locking.
Evidence
GUI automation needs a desktop that Windows is actually drawing, and both of those actions take it away.
By default the Remote Desktop client tells the remote session it is not visible, and Windows switches that session to a GUI-less mode.
SendInput style calls simply have no live desktop to deliver to, which is why the tool reports success while nothing moves.
- Record date: 2026-11-03T07:13:58.449Z