How to change or set the scaling in an RDP session?
Root Cause: Per RDP protocol, scaling for a session gets set at the time of the session creation. The scaling that is used for the session is defined by the client computer making the connection. In the case of when the Robot Service creates a session, a default scaling value of 100% is used.
Once a session is created, there is no way of changing this dynamically. Additionally, currently an option is not provided for configuring this value. As such, the only way to not use the default value is to have the target computer ignore the client settings (client here is the computer that is making the RDP session).
Resolution: Create / Modify the following registry key entries on the remote computer:
- The registry key that is used to specify the resolution.
- Registry Key Location: HKEY_CURRENT_USER\Control Panel\Desktop\LogPixels
- Registry Key (32Bit Dword): LogPixels
- If LogPixels does not exist then create it
- Type in a Decimal Value. For a list of the possible values see of the DPI related APIs and Registry Settings .
DPI
|
Scale factor
|
---|---|
96
|
100
|
120
|
125
|
144
|
150
|
192
|
200
|
- The registry key that tells the remote connection to ignore the client scaling
- Registry Key Location: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\
- Registry Key (32Bit Dword): IgnoreClientDesktopScaleFactor
- Turn on = 1
- Turn off = 0