HP QTP cannot take screenshots of issues when RDP session is minimized

The issue:
RDP does not paint the screen on the local client if it is minimized or it doesn’t think it has an active console/rdp session. The result is when users run tests in QTP while connecting to a remote machine via RDP and that RDP session is minimized QTP collects blank screenshots.

Steps to Reproduce:
1. User Logs onto computer 1
2. User connects via RDP to machine with QTP. This machine is configured with no screensaver/rdp disconnects. As a result, you can RDP into these and they stay active forever (this allows the users to run long running tests)
3. User runs the HP QTP tests on the machines from step 2.
4. User minimizes the RDP session created in step 2.

Note: This also happens if computer 1 is connected to via RDP and the user disconnects from this machine.

In this case TS client detects the lack of a screen and stops painting the window. The TS client communicates with the sever (the VDIs in step 2) telling it that there is no need to paint the screen to save bandwidth. When QTP takes a screen shot, there is nothing to screen shot.

The Fix:
Force the TS client to paint the screen regardless if it thinks it needs to:

HKEY_LOCAL_MACHINE\Software\Microsoft\Terminal Server Client\
DWORD: RemoteDesktop_SuppressWhenMinimized = 2

HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Terminal Server Client\
DWORD: RemoteDesktop_SuppressWhenMinimized = 2

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s