[Tips] Browse folders in CMD or PowerShell

In this tip, you will see how QAP can help system administrators and power users change folders instantly in Windows command line (CMD) or PowerShell. This trick is very simple but frequent users of these tools must not ignore it! You will also see how to add the various flavors of these tools to your QAP menu and how to make them run with or without administrative privileges.

Launch the Windows command line: hit Windows + R and enter CMD. Open the QAP menu with the Middle Mouse Button while the mouse is over this CMD window (or, if you prefer the keyboard trigger, make sure the window is active and hit Windows + W).

In the QAP menu, select a folder (in this example, the Program Files folder). When the folder is clicked, QAP instantly sends to the CMD window the command to move to this folder. Try the same operation using PowerShell and see that is adapting the command to PowerShell syntax.

That's it! For more info, see: Can I change folder in Windows command line CMD or PowerShell?

Running as an admnistrator

Now, let's add a favorite to your menu to open the CMD window or PowerShell with or without administrative rights. First, to make it easier to add these applications to your menu, launch an instance each of these:

  • CMD
  • PowerShell
  • PowerShell ISE

In the Settings window, click the Add button and select the Application type. Click Continue. In the Basic Settings tab, see the list of running application. In this list, select CMD or one of the flavors of PowerShell. The Application (path and filename) field will be updated automatically. Edit the Short name for menu if you wish. For this example, I would call this example Command Line Admin.

Go to the Advanced Settings tab. To launch CMD or PowerShell with admin rights, click the Elevate application with administrative privileges checkbox (see the note below).

If you create a favorite for PowerShell, the Start in field can be used to set the starting location. In some version of Windows, this option was not considered when launching a CMD window. But, as illustrated in this example, you can instruct QAP to open the CMD window already located in a folder (C:Windows\, in this example) by entering it in the Parameters field. Be careful to enter the quotes as illustrated.

Save your changes in the Settings window and test your new favorite(s).

Important notes about Admin mode

If you choose to launch CMD or PowerShell with the admin rights, depending on you User Access Control (UAC) level settings of your system, Windows could display a warning message or prompt you for the administrator password.

Also, it is important to remember that QAP will not be able to display its menu or change folder in a CMD or PowerShell window running with elevated privileges if it is not running itself with admin rights. To launch QAP with admin rights, you have different options. One of them is to select the  Run as administrator check box in QAP's Options.

See these pages in the QAP knowledge base for more information:

Please use the new QAP Support Google Group to ask questions or post comments.