IRdpClient
Provides safe, logged access to the properties, methods, and events exposed by the underlying RDP ActiveX control.
Type
RoyalApps.Community.Rdp.WinForms.Controls.Clients.IRdpClientUsed By
Properties
AcceleratorPassthrough (bool) ↗
Specifies whether keyboard accelerators should be passed to the server.
AllowBackgroundInput (bool) ↗
Specifies whether the client can accept input while it does not have focus.
AudioCaptureRedirectionMode (bool) ↗
Specifies whether the default audio input device is redirected from the client to the remote session.
AudioQualityMode (AudioQualityMode) ↗
Specifies the audio quality mode.
AudioRedirectionMode (AudioRedirectionMode) ↗
Specifies how audio output is handled for the remote session.
AuthenticationLevel (AuthenticationLevel)
Specifies the server authentication level used for the connection.
AuthenticationServiceClass (string) ↗
Specifies the service principal name (SPN) to use for authentication to the server.
AxName (string)
Gets or sets the name of the underlying RDP ActiveX implementation, for example mstsc or msrdc.
BandwidthDetection (bool) ↗
Specifies whether bandwidth changes are detected automatically.
BitmapCaching (bool) ↗
Specifies whether bitmap caching is enabled. Persistent caching can improve performance but requires additional disk space.
ClientProtocolSpec (ClientSpec)
Specifies the RDP protocol profile used between the client and the server.
ColorDepth (int) ↗
The color depth (in bits per pixel) for the control's connection. Values include 8, 15, 16, 24, and 32 bits per pixel.
Compression (bool) ↗
Specifies whether compression is enabled.
ConnectionState (ConnectionState)
Gets the current connection state of the control.
ConnectToAdministerServer (bool) ↗
Specifies whether the ActiveX control should attempt to connect to the server for administrative purposes.
ContainerHandledFullScreen (int) ↗
Specifies whether the container-handled full-screen mode is enabled.
ContainsFocus (bool)
No summary available.
DesktopHeight (int) ↗
Specifies the initial remote desktop height, in pixels. This property must be set before connecting.
DesktopScaleFactor (uint) ↗
Gets or sets the desktop scale factor for the monitor.
DesktopWidth (int) ↗
Specifies the initial remote desktop width, in pixels. This property must be set before connecting.
DeviceScaleFactor (uint) ↗
Gets or sets the device scale factor for the monitor.
DisableClickDetection (bool)
When true, a click in the remote session does not focus the control and does not trigger the IRdpClient.OnClientAreaClicked event.
DisableCredentialsDelegation (bool) ↗
When true, reusable credentials are not delegated to the remote server.
DisableUdpTransport (bool)
Disables RDP UDP transport and forces TCP transport. This is commonly useful when connecting through UDP-based VPN links.
DisplayConnectionBar (bool) ↗
Specifies whether to use the connection bar. The default value is true, which enables the property.
Domain (string?) ↗
Specifies the domain to which the current user logs on.
EnableAutoReconnect (bool) ↗
Specifies whether the client control should reconnect automatically after a network interruption.
EnableHardwareMode (bool)
When true, hardware-assisted graphics decoding is attempted.
EnableMouseJiggler (bool)
When true, the session is kept alive through periodic, non-intrusive input simulation to help avoid idle-time disconnects.
EnableRdsAadAuth (bool)
Specifies whether Microsoft Entra ID is used to authenticate to the remote PC.
EnableWindowsKey (bool) ↗
Specifies whether the Windows key can be used in the remote session.
FullScreen (bool) ↗
Specifies whether the client control is in full-screen mode. This property can be changed while connected.
FullScreenTitle (string) ↗
Specifies the window title displayed when the control is in full-screen mode.
GatewayCredSharing (bool) ↗
Specifies whether the same credentials should be reused for both the RD Gateway server and the target session host.
GatewayCredsSource (GatewayCredentialSource) ↗
Specifies the Remote Desktop Gateway (RD Gateway) authentication method.
GatewayDomain (string) ↗
Specifies the domain name used to authenticate to the Remote Desktop Gateway (RD Gateway) server.
GatewayHostname (string) ↗
Specifies the host name of the Remote Desktop Gateway (RD Gateway) server.
GatewayPassword (string) ↗
Specifies the password used to authenticate to the Remote Desktop Gateway (RD Gateway) server.
GatewayProfileUsageMethod (GatewayProfileUsageMethod) ↗
Specifies whether to use default Remote Desktop Gateway (RD Gateway) settings.
GatewayUsageMethod (GatewayUsageMethod) ↗
Specifies when to use a Remote Desktop Gateway (RD Gateway) server.
GatewayUsername (string) ↗
Specifies the user name used to authenticate to the Remote Desktop Gateway (RD Gateway) server.
GatewayUserSelectedCredsSource (GatewayCredentialSource) ↗
Specifies the user-selected Remote Desktop Gateway (RD Gateway) credential source.
GrabFocusOnConnect (bool) ↗
Specifies whether the client control should have focus while connecting. The control does not attempt to grab focus from a window running in a different process.
Handle (IntPtr)
No summary available.
IsDisposed (bool)
No summary available.
IsHandleCreated (bool)
No summary available.
KeepAliveInterval (int) ↗
Gets or sets the interval, in milliseconds, between keep-alive packets.
KeyboardHookMode (int) ↗
Specifies how Windows keyboard shortcuts, for example ALT+TAB, are redirected to the remote session.
KeyboardHookToggleShortcutEnabled (bool)
When enabled, ctrl+alt+space can be used to toggle between local and remote keyboard hook modes. Only works when the session is in full screen mode.
KeyBoardLayoutStr (string) ↗
Specifies the input locale identifier, formerly called the keyboard layout, used for the connection.
LoadBalanceInfo (string) ↗
Specifies the load-balancing cookie written into the initial X.224 connection request.
Logger (ILogger)
Gets or sets the logger used by the RDP client wrapper.
MaximizeShell (bool) ↗
Specifies whether programs launched with IRdpClient.StartProgram should be maximized.
MaxReconnectAttempts (int) ↗
Specifies the number of times to try to reconnect during automatic reconnection. Valid values are 0 to 200.
MouseJigglerInterval (int)
Gets or sets the interval, in seconds, between mouse-jiggler keep-alive actions.
MouseJigglerMethod (KeepAliveMethod)
Gets or sets the mouse-jiggler method. MouseMove simulates mouse input and KeyboardInput simulates an F15 key press.
NegotiateSecurityLayer (bool) ↗
Specifies or retrieves whether the negotiation security layer is enabled for the connection.
NetworkConnectionType (uint) ↗
Gets or sets the network connection type reported to the server.
NetworkLevelAuthentication (bool) ↗
Specifies whether the Credential Security Support Provider (CredSSP) and network-level authentication are enabled for this connection. Availability depends on the underlying ActiveX client version.
Password (string?) ↗
Sets the Remote Desktop ActiveX control password in plaintext form. After it is set, it cannot be retrieved in plaintext form.
PasswordContainsSmartCardPin (bool)
Specifies whether the password contains a smart card PIN.
PCB (string) ↗
Specifies the pre-connection BLOB (PCB) value sent to the server before connecting.
PerformanceFlags ↗
Specifies a set of features that can be set at the server to improve performance.
PinConnectionBar (bool) ↗
Specifies whether the UI connection bar is pinned in the lowered state.
PluginDlls (string) ↗
Specifies the comma-separated names of virtual channel plug-in DLLs to load.
Port (int) ↗
Specifies the connection port. The default value is 3389.
PublicMode (bool) ↗
Specifies whether public mode is enabled. Public mode prevents the client from caching user data locally.
RdpExDll (string)
Gets or sets the path to the MsRdpEx hook library used by the underlying ActiveX client.
RedirectCameras (bool) ↗
Specifies whether camera redirection is allowed.
RedirectClipboard (bool) ↗
Specifies whether clipboard redirection is enabled.
RedirectDevices (bool) ↗
Specifies whether general device redirection is enabled.
RedirectDirectX (bool) ↗
Specifies whether DirectX redirection is enabled.
RedirectDriveLetters (string)
Specifies the drive letters that should be redirected, for example CEH for drives C:, E:, and H:. If empty, all drives are redirected when IRdpClient.RedirectDrives is enabled.
RedirectDrives (bool) ↗
Specifies whether drive redirection is allowed.
RedirectedAuthentication (bool)
When true, authentication is redirected back to the local device. This property and IRdpClient.DisableCredentialsDelegation must both be enabled for IRdpClient.RemoteCredentialGuard.
RedirectLocation (bool) ↗
Specifies whether location redirection is allowed.
RedirectPorts (bool) ↗
Specifies whether local port redirection, for example COM and LPT, is allowed.
RedirectPOSDevices (bool) ↗
Specifies whether Point of Service device redirection is enabled.
RedirectPrinters (bool) ↗
Specifies whether printer redirection is allowed.
RedirectSmartCards (bool) ↗
Specifies whether smart card redirection is allowed.
RelativeMouseMode (bool) ↗
Specifies whether the mouse should use relative mode instead of absolute mode.
RemoteCredentialGuard (bool) ↗
Remote Credential Guard helps protect credentials over a Remote Desktop connection by redirecting Kerberos requests back to the device that initiated the connection. It also provides single sign-on for Remote Desktop sessions. When enabled, IRdpClient.RedirectedAuthentication and IRdpClient.DisableCredentialsDelegation are set to true.
RemoteMonitorCount (uint) ↗
Gets the number of monitors in the active remote session. Availability depends on the underlying ActiveX client version, and the property can only be read after the connection has been established.
RestrictedAdminMode (bool) ↗
Specifies whether Restricted Administration mode is enabled. In this mode, credentials are not sent to the remote PC or server.
RestrictedLogon (bool)
When true, restricted logon mode is enabled. This is one of the building blocks used by restricted administration scenarios together with IRdpClient.DisableCredentialsDelegation.
Server (string) ↗
Specifies the target server name or IP address. This property must be set before connecting.
ShowConnectionInformation (bool)
Shows the Connection Information dialog.
SmartSizing (bool) ↗
Specifies whether the display should be scaled to fit the client area of the control. This property can be changed while connected.
StartProgram (string) ↗
Specifies the program to be started on the remote server upon connection.
UseMultimon (bool) ↗
Specifies whether the Remote Desktop ActiveX control should use multiple monitors. Availability depends on the underlying ActiveX client version. This property must be set before the connection is established.
UseRedirectionServerName (bool) ↗
Specifies whether the redirected server name should be used when the broker redirects the connection.
UserName (string?) ↗
Specifies the user name logon credential.
VideoPlaybackMode (VideoPlaybackMode) ↗
Specifies whether video decoding and rendering are redirected to the client.
WorkDir (string) ↗
Specifies the working directory of the start program.
Events
OnClientAreaClicked
Handler Type: EventHandler
Raised when the user clicks inside the remote desktop session and IRdpClient.DisableClickDetection is disabled.
OnConfirmClose
Handler Type: IMsTscAxEvents_OnConfirmCloseEventHandler
No summary available.
OnConnected
Handler Type: EventHandler
No summary available.
OnDisconnected
Handler Type: IMsTscAxEvents_OnDisconnectedEventHandler
No summary available.
OnRequestContainerMinimize
Handler Type: EventHandler
No summary available.
OnRequestLeaveFullScreen
Handler Type: EventHandler
No summary available.
Methods
Connect() ↗
Returns: void
Initiates a connection using the properties currently set on the control.
Disconnect() ↗
Returns: void
Disconnects the active connection.
Focus()
Returns: bool
No summary available.
GetErrorDescription(Int32)
Returns: string. The error message text.
Retrieves the error description for the session disconnect events.
Parameters
disconnectReasonCode(int): The disconnect code.
GetOcx()
Returns: object?. The ActiveX control.
Retrieves a reference to the underlying ActiveX control.
GetRemoteMonitorsBoundingBox(Int32@, Int32@, Int32@, Int32@) ↗
Returns: void
Retrieves the bounding rectangle of the remote monitor layout. This method can only be called after the connection has been established.
Parameters
left(outint): Receives the left edge of the rectangle.top(outint): Receives the top edge of the rectangle.right(outint): Receives the right edge of the rectangle.bottom(outint): Receives the bottom edge of the rectangle.
All coordinates are in virtual screen coordinates, which are relative to the upper-left corner of the primary monitor. If this is not the primary monitor, some or all of these values may be negative.
RaiseClientAreaClicked()
Returns: void
Raises the OnClientAreaClicked event.
Reconnect(UInt32, UInt32)
Returns: ControlReconnectStatus
No summary available.
Parameters
width(uint): No description available.height(uint): No description available.
SendRemoteAction(MSTSCLib.RemoteSessionActionType) ↗
Returns: void
Performs an action in the remote session.
Parameters
action(RemoteSessionActionType): The remote session action to perform.
UpdateSessionDisplaySettings(UInt32, UInt32, UInt32, UInt32, UInt32, UInt32, UInt32) ↗
Returns: void
Updates the remote session display settings.
Parameters
desktopWidth(uint): Desktop width.desktopHeight(uint): Desktop height.physicalWidth(uint): Physical width.physicalHeight(uint): Physical height.orientation(uint): The display orientation.desktopScaleFactor(uint): Desktop scale factor.deviceScaleFactor(uint): Device scale factor.
