Your agent's clicks stop when you minimize Remote Desktop or lock the screen
Описание и применение
Автоматические агенты перестают работать, когда сеанс Remote Desktop минимизируется, отключается или экран блокируется, поскольку Windows прекращает отрисовывать рабочий стол. Решения включают изменение параметров клиента RDP, использование tscon для возврата сеанса на консоль без блокировки и переход на VNC, чтобы сохранить активный рабочий стол.
Задача
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.
Результат
Agents resume reliable operation when the desktop remains active, eliminating failures caused by minimized or locked RDP sessions.
Рабочий процесс
- 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.
Доказательства
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.
- Дата записи: 2026-11-03T07:13:58.449Z