How to open cmd in windows 10 folder. How to open command prompt as administrator in desired folder

What is command line? This is just a software shell that allows you to control some PC functions through text queries. Moreover, it used to be the only way perform some function. Now almost everyone uses a convenient interface, but the line has remained, and using it is quite simple.

How to open command line?

How to open command line in Windows XP

In principle, the methods for opening the command line are similar to each other. Differences can only be in the interface itself and inscriptions. In order to open a command prompt in Windows XP, you can use the standard start menu. Followed by "all programs" - "standard" - "command line".

You can also do the same with the keyboard shortcut WIN + R. In the window that opens, type cmd and click OK.

How to Open Command Prompt in Windows 7

Since the operating Windows system XP is somewhat similar to Windows 7, the methods are applicable in both cases. The only difference is that the standard menu method may not work because the menu is slightly different in Windows 7. Then you can use the normal search. Just type cmd in the standard search.

How to Open Command Prompt in Windows 8

In Windows 8, you cannot use the standard menu, since it simply does not exist here. At the bottom of the desktop there is an icon - "all applications". We click on it and look for the menu item "command line".

You can also use the WIN + R key combination method.

How to run command prompt as administrator?

How to open command prompt as administrator Windows XP and Windows 7

It's very easy to run Command Prompt as an administrator in Windows XP, just like in Windows 7. Through standard menu"start" launch the command line, as described above and right-click on the item, select "run as administrator".

You can do the same, but using the desktop. Create a shortcut and name it "cmd.exe". Right click on it and select "run as administrator".

How to open command prompt as administrator Windows 8

With Windows 8, things are a bit more complicated. This can be done here using the task manager. And so we start the task manager, click File then Start a new task. In the window that opens, enter cmd and a little lower check the box next to Create a task with administrator rights and click OK.

Through the explorer, open "My Computer" and select local disk, then follow this algorithm: File->Open Command Prompt -> Open Command Prompt as administrator.

The same can be done using the WIN + X keys. After pressing this key combination, a menu will appear in which we select the “command line (administrator)” item.

As you can see, each of these methods is quite simple and does not require special knowledge or skills.

It is hardly possible to imagine functional work on a computer without using the command line. Whether you like it or not, sooner or later you will still have to use it to make settings in the operating system, and absolutely regardless of whether Windows XP, 7 or 8 is installed on your PC. However, where computer geniuses have eaten the dog, novice users have to be content with painful questions. And the main one among them is how to launch the command line on the now popular Windows 8 and 7 operating systems? Perhaps it would be just cruel not to answer it.

Method number 1: Launch through the search menu

Using the search is the simplest method that can be used equally effectively to launch the command line on computers and from Windows versions 7, XP and 8. True, the performance options will differ slightly from each other.

OS Windows 7:

Open the Start menu and type "command" into the search bar. As a result, the system will independently perform a search and display a command line shortcut. It remains only to right-click on it and select "Run as ..." from the menu that appears:

In addition, you can use another search value, for example, by entering the word cmd in the search box:

In any case, whichever method you choose, as a result of such actions, the system will open the command line necessary for work:

In this version of the operating system from Microsoft, you can use the cmd command using the search bar in Metro. To do this, open the start windows screen 8 and drive in the search value cmd. As a result, the “Command Prompt” icon should appear on the left. We click on it with the right mouse button and click on the tab "Run as ..." at the bottom of the screen:

Method #2: Using the Task Manager

For some reason, this method is used by users infrequently, although in terms of its efficiency and speed it is not inferior to the method described above. True, as in starting the command line with cmd commands through the Run or Search utility, you will have to act differently in Windows 7 and 8.

OS Windows 7:

To launch the task manager, press Esc, Shift and Ctrl on the keyboard at the same time. Next, in the window that opens, we find the “File” tab and select the “New task (Run…)” option in it by clicking the left mouse button:

As a result, the "Create a new task" window will appear. In this case, you also cannot do without the cmd command. To execute it and launch the command line accordingly, enter the cmd value in the empty field of the system window and confirm your choice by simply pressing the OK button:

OS Windows 8:

To get started, just like on computers with Windows 7 installed on them, simultaneously press the Shift, Ctrl and Esc buttons on the keyboard. After that, in the window that opens, select the "File" tab, and in it the "Run a new task" section. As a result, the "Create Task" utility will open. It is quite appropriate to use the cmd command in it. Enter the word cmd in the "Open" line, and then click OK:

Method number 3: Launch using Explorer

This method does not require either running cmd or running third party programs. In this case, to run the command line on the computer, it will be enough to use the provided Windows developers 7 and 8 with the "Explorer" function.

Open "My Computer" and enter Work Drive C. Then enter "Command Prompt" in the search and press Enter. As a result, the system will find the shortcut we need. After that, it remains only to right-click on it and select "Run as ..." from the proposed menu:

Being in Metro UI press Windows tab Explorer, then we enter the Computer and select drive C. Then open the "File", find the item "Open command ..." in the menu and select the required parameter for entering:

Let's reveal a little secret here. Entering the command line, using the help command, you can get all the necessary help information about it:

Such a trick can come in handy if you accidentally forget the meaning of a particular command or are not initially sure of its effectiveness.

Method number 4: Start from a folder

For those who want to run a command line on a PC to set up a specific folder, it is enough to use this particular method. The startup time is reduced by one.

All we need is to find the required folder and, while holding down the Shift button on the keyboard, right-click on this folder, and then select "Open command window" in the proposed menu:

In this OS, everything is much simpler. It is enough to go to the desired folder and press the Alt and 2 buttons on the keyboard without changing the keystroke sequence.

Method number 5: Performing a launch through the Run utility

This method is great for computers with Windows 7 and previous versions OS. In this case, we again need the benefits of the cmd command, but first we still need to call the Run utility. This can be done by simultaneously pressing the R and buttons on the keyboard. After the utility starts, we drive in the empty field in the window the value of cmd and press OK on the screen, or Enter on the keyboard.

To do this, in Windows XP, click the "Start" button, then "Run" and type "cmd" there. In Windows 7 - the "Start" button, enter "cmd" in the search field, right-click on the result that appears and select launch from. When prompted to start, click Yes.

Now you need to find the directory in which the problem is located file. Initially, you are in the system directory "C:\Windows\System32". For the contents of the directory, type "dir / p" ("p" is responsible for paging) and the computer will give you a list file ov and subdirectories, to go to the next page, use the Enter button. In Windows 7, "p" is optional, since this OS has the ability to scroll the contents of the command lines. To display directories alone, use the "/ad" ("dir /ad") key, only file ov - the key "/b" ("dir /b").

To move to a directory, use the cd command.< путь к каталогу >” (for example, typing “cd C:Windows”, you will be taken to the Windows directory, from the initial one you can also get there “cd ..”, which serves to go one level back). If you need to change the disk - enter "< >:" (for example "D:").

Now that you have found the directory, and in it you need file- it remains only to enter the name of this file a. The file will open with a program that set parameters should open it. In the future, it is not necessary to go to the directory with file oh, just remember the full path to it (see the image for the step).

By entering commands into "Command line" in operating systems Windows family, you can solve a variety of tasks, including those that, through GUI cannot be solved or it is much more difficult to do so. Let's see how in Windows 7 you can open this tool in various ways.

Interface "Command line" is an application that provides the relationship between the user and the OS in textual form. The executable file for this program is CMD.EXE. In Windows 7, there are quite a few ways to call the specified tool. Let's find out more about them.

Method 1: Run window

One of the most popular and simple ways call "Command line" is to use windows "Run".


The main disadvantages of this method are that not all users are accustomed to keeping in mind various hotkey combinations and startup commands, as well as the fact that activation cannot be performed in this way on behalf of the administrator.

Method 2: Start Menu

Both of these problems are solved by launching through the menu "Start". Using this way, it is not necessary to keep in mind various combinations and commands, and you can also launch the program of interest to us on behalf of the administrator.


Method 3: Using Search

The application we need, including on behalf of the administrator, can also be activated using the search.


Method 4: Running the executable directly

As you remember, we talked about launching the interface "Command line" produced using executable file cmd.exe. From this we can conclude that it is possible to launch the program by activating given file by going to its location directory with Windows Explorer.


At the same time, it is not at all necessary to use the address bar to go to the CMD.EXE location directory in Explorer. Moving can also be done using the navigation menu located in Windows 7 on the left side of the window, but, of course, taking into account the address that was indicated above.

Method 5: File Explorer Address Bar


Thus, you don’t even have to look for CMD.EXE in Explorer. But the main drawback is that specified method does not provide activation on behalf of the administrator.

Method 6: launch for a specific folder

There is a rather interesting activation option "Command line" for a specific folder, but, unfortunately, most users do not know about it.


Method 7: forming a label

There is an option to activate the "Command Line" by first creating a shortcut on the desktop that refers to CMD.EXE.

  1. Click PKM anywhere on the desktop. In the context list, stop the selection on "Create". In the additional list, go to "Label".
  2. The Create Shortcut window will open. Click on the button "Review…" to specify the path to the executable.
  3. A small window opens, where you should go to the CMD.EXE location directory at the address that was already agreed upon earlier. Select CMD.EXE and press OK.
  4. Once the object's address is displayed in the create shortcut window, click "Further".
  5. In the field of the next window, a name is assigned to the shortcut. By default, it corresponds to the name of the selected file, that is, in our case cmd.exe. This name can be left as it is, but you can also change it by entering any other name. The main thing is that by looking at this name, you understand what exactly this shortcut is responsible for launching. For example, you can enter the expression "Command line". Once the name has been entered, press "Ready".
  6. The shortcut will be generated and displayed on the desktop. To launch the tool, just double-click on it. paintwork.

    If you want to activate on behalf of the administrator, then you should click on the shortcut PKM and select from the list "Run as administrator".

    As you can see, to activate "Command line" using the shortcut, you will have to tinker a little once, but in the future, when the shortcut has already been created, this option for activating the CMD.EXE file will be the fastest and easiest of all the above methods. At the same time, it will allow you to run the tool both in normal mode and as an administrator.

There are quite a few launch options. "Command line" in Windows 7. Some of them support administrator activation, while others do not. In addition, it is possible to run this tool for a specific folder. Most the best option To always be able to quickly launch CMD.EXE, including as an administrator, is to create a shortcut on the desktop.

By editing the registry, you can add the "Open command window" option for all folders to the main Explorer context menu that appears when you right-click on an object.

If you right-click on a folder in or Vista, the main context menu will appear (Figure A). And if you hold down the key, an extended context menu with additional options becomes available (Fig. B).

Figure A. Context menu.


Figure B. Extended context menu with key.

That's all great, but what if you want the "Open Command Window Here" option to appear in the main context menu, which opens on right-click without the ? To do this, you will have to edit the registry.

Registry editing

In Windows 7, open the Start menu (Start) and type in the search bar "regedit" (without quotes) in the search bar. Select "regedit.exe" in the search results and confirm the operation in the User Account Control window. In the Registry editor (Fig. C) find the section " HKEY_CLASSES_ROOT\Drive\shell\cmd».


Figure C. Registry Editor.

In the right pane, highlight the "Extended" option, right-click on it, and rename it to something else (Figure D). It is possible to remove this setting altogether, but in this case it will be more difficult to restore the default settings if necessary. Renaming/removing this setting adds the "Open Command Window" option to the context menu for drive icons in Explorer.


Figure D. Extended option.

To add this option to the context menu for all folders in Explorer, look in the Registry Editor for the " HKEY_CLASSES_ROOT\Directory\shell\cmd”, in the right panel, select the “Extended” option (Fig. E) and rename or delete it.


Figure E Another "Extended" option.

Then close the Registry Editor. Now, when you right-click on a drive or folder in Explorer, the option "Open command window" will be available in the context menu (Fig. G).


Figure G The "Open command window" option is now available in the main context menu.

Internet