First, I found that a server option is required to enable the Terminal Services Authorized Services.
- On the terminal server, click the Start button, select Programs, Administrative Tools, and then click Connect to Terminal Server Configuration.
- Double-click the rdp-tcp connection and click Advanced. If you want to change the properties for ICA Clients, double-click the ica-rdp icon instead, and then click Properties.
- In the AutoLogon section, click to clear the "Password Verification Request" box.
- Click OK, then OK, and then Exit from the Connection menu.
source: support.microsoft.com/kb/260711
After that, I did something based on this project: codeproject.com/KB/cs/RemoteDesktop_CSharpNET.aspx For what I tested, I think it is impossible to skip the RDP client connection (MsTscLib or mstsc.exe) I have something- that works, but it is definitely a bad style. I use ActiveX Component Events to find out the result of the connection. That is: OnLogonError and OnLoginComplete.
here is my source: http://codepaste.net/uiuuxc
I am waiting for your comments.
adun source share