IMsRdpClipboard mstscax.dll always return null

Maogang MG2 Chen 1 Reputation point
2021-09-14T09:04:30.43+00:00

I use MsRdpClient9NotSafeForScripting in my winforms app.

Bellow is my code.
//code begin
private AxMSTSCLib.AxMsRdpClient9NotSafeForScripting rdp;
IMsRdpClientNonScriptable7 msRdpClientNonScriptable7 = (IMsRdpClientNonScriptable7)rdp.GetOcx();
object value = true;
extendedSettings.set_Property("ManualClipboardSyncEnabled", ref value);
IMsRdpClipboard clipboard = msRdpClientNonScriptable7.Clipboard;
if(clipboard != null)
{
clipboard.SyncLocalClipboardToRemoteSession();
}
// code end

The cliipboard is always null.
Why?

And I find no class implements IMsRdpClientNonScriptable7, then how to use this interface?

Remote Desktop
Remote Desktop
A Microsoft app that connects remotely to computers and to virtual apps and desktops.
4,243 questions
{count} votes