The Run command for Windows Remote desktop application is
Just open Run from start menu and type mstsc in the text box next to open and press enter.
mstsc can be used from command line too.
A system running Windows 7/Windows 10 allows only one remote desktop connection at a time, means only one remote user can work on it any time. A computer running Windows server edition can support remote sessions for multiple users at the same time.
Every time we connect to the server it opens a new user session. To avoid this we can open a connection to the console. This allows us to login back to the same user session if we already have one. To do this we need to add
/console switch to the
This command can be run from command prompt or from Run window.
Run command for opening remote desktop session in full screen mode
/f switch to the command.
Run command for specifying the remote computer name from the command itself
/v switch in this case.
Run command to specify remote desktop connection settings using a rdp file
A RDP file can be created using the ‘Save As‘ button in the General tab in mstsc(Remote desktop connection client) window.
These commands work on XP, Vista, Windows 7 and Server 2003/2008 operating systems.
Run command for Remote desktop manager
There is no Run command for opening remote desktop connection manager directly. It is usually installed in the path
C:\Program Files\Remote Desktop Connection Manager\RDCman.exe. By specifying this complete path we can launch connection manager.
How to enable Remote desktop from command line
Good information on the command line switches available with the mstsc command. thank you.
i would like to write command script to check whether the servers could RDP or not.
we have around 30 servers hence cant run mstsc /v:servername for each. Hence just would like to write cmd script to check all the servers. Could you please help me ?
You could do this by verifying the port is open through powershell.
test-netconnection -Port 3389
can you please assist me with the system to enable remote access desktop/working into the network user without being there physically,i have i.p address and computer name of the workstation and we are all in one network.
Possibly you only have Windows Home Edition, which doesn’t support Remote Connections.
Remote Desktop Assistance is a feature of Windows Pro Editions.
can user able to see the desktop in mstsc command
It is not mstsc/console anymore. Now it is mstsc/admin. You can also add it to a desktop shortcut by changing the Target to %windir%\system32\mstsc.exe -admin
“admin” is different than “console” actually. Admin allows you to boot another user. My bad.
Hello..is there any option to trigger MSTC on windows boot up, preferably with pre-specified destination server and credentials?
Also, if the user logs out of the terminal server, he should get logged out of the local desktop as well.
I don’t want to give the user the option of a local desktop.
The local desktop is a Windows 7 system.
Clever Idea, You could effectively make a machine run like a terminal. You could probably put something together within AutoIT to launch the exact path for the remote desktop software and then create an event within your au3 script that checks for mstsc.exe to see if it is running and in the event that it isn’t it could trigger a logout. Which according to this website is the command logoff
You could also potentially replace the explorer shell with your application by editing the registry at HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Winlogon\Shell
and setting explorer.exe to your AutoIt Program name. I suspect your program would have to be in the same folder as explorer.exe. Also if someone else finds a way to launch explorer.exe it would only function as a file manager, it shouldn’t bring a desktop up. This should also prohibit most windows hotkeys like Win+R since your program doesn’t map it and explorer isn’t running to catch it, I think mostly the Ctrl+Alt+Del would work, but not too many others (Win+L would probably still work or is it Win+K, whatever it is to lock the screen).
Thank’s very gooooood
Very Informative… I use RDP and I usually Need these commands
Great commands cheers!
Open a CMD window ( + R, then type CMD ). Now type:
Now press the key.
This will give you a list of the swtches.
Please let me know how to automatically transfer files from local machine to remote machine using RDP command prompt
Very helpful tips,
I will use the same to solve issues of my company Indiaaccess Servers and Hostasp Servers
Thanks for your info
So, what do you do if it is your laptop, and someone has remote accessed your laptop- and you want to keep them out?
How do I stop NT Authority user Special Logon privilege assume system owner from changing my Personal single user home Desktop into a computer controled by an organization Administrator with control of Group Policy. I am allowed to use my computer, but I am denied access to make any changes to Windows 11 Services, Features and Group Policy