WindowsPowerShell is a command line shell designed for system administrators and used in Windows operating systems. Windows PowerShell can be used as an interactive prompt and scripting environment, independently or in combination. However, many PowerShell commands require elevated or administrator rights, and you need to launch a PowerShell prompt to execute them.

#How to run PowerShell as an administrator in Win10.
Method 1: Use the Windows 10 Start Menu context menu.
When you right-click on the Windows 10 Start menu, a context menu appears, allowing you to quickly launch commonly used management programs.
The context menu contains an option called WindowsPowerShell(Admin) as shown below.

To launch the upgrade PowerShell prompt, click the Windows PowerShell (Administrator) option.
Windows 10 will now display a UAC prompt asking you if you have permission to grant program improvements. Click Yes at this prompt.

The PowerShell prompt will now open. Since the starting directory will be C:\Windows\System32, the window title will be Administrator: WindowsPowerShell.

Once you are done with the prompt, you can click the X or type exit and press Enter to close it.
Method 2: Start PowerShell from an elevated command prompt.
If you have an elevated command prompt open, you can simply enter powershellEnter to start powershell.

When launched this way, the PowerShell prompt looks a little different because the background is not blue and it runs as a shell in a traditional command prompt.
You can type exit and press Enter to return to an elevated command prompt.
The above is the detailed content of How to run PowerShell as an administrator in Win10.. For more information, please follow other related articles on the PHP Chinese website!
The difference between powershell and cmd
How to run cmd as administrator
What are the components of a linux system?
What does win11 activation status activity mean?
Introduction to Java special effects implementation methods
How to solve 0xc000409 error
Usage of ModifyMenu
What should I do if msconfig cannot be opened?