Quantcast
Channel: .NET Framework Class Libraries forum
Viewing all articles
Browse latest Browse all 8156

Login to a remote desktop using MSTSCLib

$
0
0

I am trying to log in on a remote desktop. I am able to open the login screen with the following code. (rdpSP is a Microsoft Terminal Server Client Control - version 1)

rdpSP.Server = "the IP";
  rdpSP.Domain = "the domain";
  rdpSP.UserName = "the username";
  MSTSCLib.IMsTscNonScriptable secured = (MSTSCLib.IMsTscNonScriptable)rdpSP.GetOcx();
  secured.ClearTextPassword = "the password";
  rdpSP.Width = this.Width;
  rdpSP.Height = this.Height;
  rdpSP.Connect();

Now I can see the login screen and the user domain/username. But the password isn't used. Is it possible to log in automaticly or at least fill in the password?


Viewing all articles
Browse latest Browse all 8156


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>