Computer help - file server

[ Blog ] - [ File Server ] - [ Удаленная компьютерная помощь ]

If you`re in IT, you probably have to use the command prompt quite often. You also probably have to navigate to specific folders and run certain commands or executables from that location. I don`t know about you, but having to type in CD foldername ten times is pretty annoying. Of course, there are shortcuts and you can actually just type one command to get to any folder you like, but who really wants to type out the full path, especially if its long.

Instead, it`s nice to be able to open a command prompt directly from Explorer starting in the folder of your choice. Now there are tons and tons of registry hacks and programs out there that help you add these extra options to your right-click context menu, but this isn`t actually necessary on all versions of Windows. If you are running Windows 7, Windows 8 or Windows 10, the option is already built-in, you just have to press a key before right clicking. I`ll explain further down.

If you are using Windows XP or Windows Vista, well, you should first read my article on why you should no longer be using Windows XP. If you`re on Vista, ask yourself why? Then upgrade to Windows 10 if you hate Windows 8. Otherwise, you have to use one of those registry hacks or annoying programs that add options to your context menu.

Note: With Windows 10, Microsoft is really pushing PowerShell over Command Prompt. It`s now been replaced by PowerShell from the Power User menu (Windows key + X) and from the File menu in Explorer. It was there in Windows 8, but it`s gone now.  Add Command Prompt to Context Menu

So in Windows 7 and 8, all you have to do is hold down the SHIFT key and then right-click on a folder:

You`ll see an option called Open command window here. This will get you a command prompt with the path to the folder set as the starting point.

Unfortunately, as mentioned earlier, this doesn`t work on Windows 10. Instead, it now says open Windows PowerShell window here. It`s worth mentioning that you can run all of the command prompt commands in PowerShell, but some require a bit tweaking of the syntax. Check out this article that explains how you can run command prompt commands in PowerShell.

But that`s not the only way to open a command prompt to a folder while in Explorer. Let`s say you are browsing around and you quickly want to open a command prompt for the folder you are currently viewing. Using the method above, you would have to click back to go to the parent folder, then hold down SHIFT, right-click and then open the command prompt.

If you don`t want to do that or navigate away from the folder, just click up in the address bar, delete everything and type in CMD. BAM! You get a command prompt set to that folder!

Make sure to press Enter after typing CMD. Pretty sweet, eh? If you are a PowerShell user, instead of typing CMD, you just type powershell and you`ll get a PowerShell window set to that folder. This works in Windows 10, 8 and 7.

The only issue here is how to open an elevated command prompt instead of just a normal prompt. Now that is unfortunately not as easy. In Windows 8, you can do this from Explorer by clicking on the File menu and selecting either Open command prompt or Open Windows PowerShell. There you will have the option for a regular or elevated command prompt.

This will still open the command prompt to the folder that you are currently in, so that`s a good thing. Unfortunately, this only exists on Windows 8. You can`t do this on Windows 7 or Windows 10. Actually, Windows 10 has the option for opening in Windows PowerShell, but removed the Command Prompt option.

Luckily, there is a simple trick you can perform in Windows 7/10 and earlier that will fix the issue. It`s not the safest thing to do, so I don`t recommend it unless you know what you are doing. So if you want Windows to open a command prompt as Administrator by DEFAULT, you can do this by turning off UAC.

You can also disable UAC in Windows 8/10, but I really don`t recommend that because it can cause a lot of system issues. On Windows 7 and earlier, it just makes your system less secure.

So if you don`t want to disable UAC in Windows 7/10, but still want to open an administrative command prompt, you`ll have to go ahead and do the registry hack and add an option in the right-click context menu. You can read this article on how to add the registry key. Again, if you`re using Windows 10, try to move over to PowerShell as that is the future and you can still run all your old commands in it, just with some syntax tweaking. Enjoy!