BT游戏为游戏而生,让游戏更简单、快乐!
XML地图  |  收藏本站
当前位置:首页 > 资讯教程 > 系统教程 > 正文

Win10系统右键添加Powershell和命令提示符方法

更新时间:2026-02-04 01:13:01编辑:昔日&
360集合包
360集合包
360集合包,一键装机、快捷方便。
立即下载   精品合集
Win10系统可以通过SHIFT+右键的方式呼出右键菜单中的Powershell控制台选项,但是对于经常需要操作的用户来说不免有些麻烦,下面小编分享的方法是不需要按Shift右键就可以的,下面一起来看看。


 

; 若原先有,先删除原来的[-HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHere][-HKEY_CLASSES_ROOT\Directory\Background\shell\runas][-HKEY_CLASSES_ROOT\Directory\Background\shell\PowershellAdmin] ;1.右键:命令行[HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHere]@="在此处打开命令行窗口" [HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHere\command]@="cmd.exe -noexit -command Set-Location -literalPath \"%V\"" ;2.右键:命令行(管理员)[HKEY_CLASSES_ROOT\Directory\Background\shell\runas]@="在此处打开命令行窗口(管理员)""ShowBasedOnVelocityId"=dword:00639bc8 [HKEY_CLASSES_ROOT\Directory\Background\shell\runas\command]@="cmd.exe /s /k pushd \"%V\"" ;3.shift+右键:Powershell(管理员)[HKEY_CLASSES_ROOT\Directory\Background\shell\PowershellAdmin]@="在此处打开 Powershell 窗口(管理员)""Extended"="" [HKEY_CLASSES_ROOT\Directory\Background\shell\PowershellAdmin\command]@="\"C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.exe\" -windowstyle hidden -Command $stpath = pwd; Start-Process PowerShell -ArgumentList \\\"-NoExit\\\", \\\"-Command Set-Location -literalPath '%V'\\\" -verb RunAs"


;4.设置右键 管理员打开cmd的另一种方法(可用来替换上面的2) 通过Powershell调起,会闪过一次Powershell的窗口,去掉下面几行的[; ]可以取消注释[-HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHereAdmin][HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHereAdmin] @="在此处打开命令行窗口(管理员)"[HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHereAdmin\command]@="PowerShell -windowstyle hidden -Command \"Start-Process cmd.exe -ArgumentList '/s,/k, pushd,%V' -Verb RunAs\""

扫一扫,访问手机页面
版权、建议等问题请点击投诉反馈
最新专题更多
猜你喜欢更多
24小时热门文章
小编推荐
近期热点
热门专区
手机扫一扫轻松打开
3DM游戏网