While talking about the 15 amazing Run Box commands the other day, I mentioned how both Run Box and Command Prompt are treated as a bit nerdy. Well, one might work on Windows without even touching the Run box but you cannot run away from Command Prompt (cmd). No matter how good Windows may evolve on the GUI front, Command Prompt (or more accurately, the Command Line ) was how it all began.
So here are some great tips you can use to make yourself comfortable while working with the Command Prompt. First things first, the shortcut for Command Prompt is cmd and that’s all you need to type in the Run box or the Start search in order to bring it up.
Now on to the cool Command Prompt tricks, which might be known ones for the geeky ones among you, but on the other hand, have the potential to incite the a-ha moment for many other everyday computer users among you.
When you open the command prompt, it opens up in either User or System folder depending upon whether you ran it as administrator or not. Now the thing is, if you want to execute a file in any particular folder, you would have to use the change directory(cd) command to navigate to the folder which can be a problem if the directory is nested way too deep.
To ease things you can open the folder in your Windows Explorer, hold Shift key when you right-click in the folder and select Run command window here to directly open the CMD prompt with the path to that folder directly.
2. Enable QuickEdit for Easy Copy/Paste
One thing I miss the most in Windows Command Prompt for is the ability to easily copy and paste text using the conventional Windows hotkeys. Normally, one would have to use the right-click context menu options to copy and paste text, but if you enable QuickEdit, you can do them using simple shortcuts.
To enable the QuickEdit mode, right-click on the Command Prompt Title Bar and select Properties. In the Properties Window under the Option Tab enable QuickEdit Mode. That’s all; you can now quickly select text by dragging your mouse pointer. Pressing the enter key on the selected text will copy the text to the clipboard, and a simple left click would be enough to paste the text.
Thankfully, after the Windows 10 update, copy pasting on Windows is as easy as pie. All you need to do is use the copy shortcut,Ctrl+C, from the source and than paste it on the Command Prompt window. That's it!
Many commands require you to run command prompt as administrator. When you search for CMD in Start Menu, other than selecting Run as administrator from the right-click menu, you can simply press Ctrl+Shift+Enter to open it with admin privileges.
This trick will work for all the programs installed on your system.
4. See Command History
It's no secret that you can see the last used commands of a session using the the navigation arrow keys, but if you would like to see a list of all the commands, you can get it by pressing the function keys.
Alternatively, you can use the command doskey /history to list these commands in the command prompt itself.
Are you bored with the conventional black-and-white looks of the command prompt and would like to paint it different? We have already covered a guide on how you can customize your command prompt which you can refer to make the changes.
Many a times, I often find myself copying a command's output to a clipboard. Especially, when at times when I get an error, and want to paste the exact same text in an email or chat.
Add the command | clip at the end of the command
The good thing is that these command output can be can be easily stored to a clipboard through this useful command.
Add the command | clip at the end of the command and that will take care of the rest. For instance, Dir /p | clip
7. Drag and Drop Files to Change Path
Another useful command prompt trick is that if you want to copy the exact path to a folder or file to run the file or change the present working directory, you can simply drag and drop the file or the folder on the command prompt.
The path of the dropped file or folder will show up in quotes.
8. Run Multiple Commands
Another nifty cmd trick is that you can run multiple commands simultaneously. All you have to do is put && between two commands and execute them one after another.
The command on the left will execute first followed by the command on the right of the double ampersand.
9. Get Help for Command
Well let’s say you know about a command, but you are not sure how it works. Not a problem, all you need to do is suffix the command with /? and execute it. If the command is valid, the command prompt will give you all the information related to it.
10. Watch Star Wars in ASCII
For all my nerdy friends who are diehard fans of Star Wars, you can actually watch the Star Wars Episode IV movie in the command prompt. Though it would be in ASCII, it will be fun.
To start the movie, open command prompt, type in telnet towel.blinkenlights.nl. and press enter. Don’t forget the popcorns though.
Please note that the above functionality might not be enabled by default. To enable Telnet, head over to the Control Panel > Program and Features > Turn Windows feature on or off and check the option for Telnet Client.
11. Create a Wi-Fi Hotspot
Another cool thing that you can do with Command Prompt is creating a WiFi hotspot on your Windows PC. Yes, there are many third-party tools which help in achieving the same, but remember 'Geeky'? A set of simple commands is all it takes to share your Internet connection with your buddies.
A set of simple commands is all it takes to share your Internet connection with your buddies.
Before you type the following command on the Command prompt window, make sure that you're running it as an Administrator.
NETSH WLAN show drivers
The Hosted network supported command output lets you know whether your PC supports WiFi sharing. If the field displays Yes, it means that your system is capable of WFi sharing. Once verified, enter the following command,
netsh wlan set hostednetwork mode=allow ssid=[Name] key=[Pwd]
Here, Name is the supposed network name and Pwd is the password. Now all you have to do is enter the final command,
netsh wlan start hostednetwork
Now, let your friends sit back and enjoy the perks of a free Internet connection, all thanks to you.
I am sure these tricks will make you a little more comfortable with the Windows Command Prompt. If you are one of our more tech savvy readers who has been relying on the Command Prompt for years, why not share some cool tricks that you’ve got up your sleeve? Chip in with your comments!