I'd like to know if there is a way to create and launch a Remote Desktop Session on a Windows Server programmatically.
I'm trying to make an automatic tool to create Local Users and then launch the associate RDP session. I've already made LocalUser creation and adding them to Remote Desktop Users (using net.exe). But I'm struck with the next step : create and launch user's rdp-session. I don't know how to handle this problem without having the Remote Desktop Client Gui.
I'm working on a Windows Server 2003 and I'm using VS2008 with .NET 3.5.
Regards.
You can call mstsc.exe and pass parameters on the command line to tell it what to connect to.
mstsc.exe documentation on MSDN
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With