1、首先建立記事本,復制以下代碼到記事本中,另存為.reg格式,雙擊注冊表即可獲得管理員權限。
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT*shellrunas]
[HKEY_CLASSES_ROOT*shellrunas]
@="獲取超級管理員權限"
"Icon"="C:WindowsSystem32imageres.dll,-78"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOT*shellrunascommand]
@="cmd.exe /c takeown /f "%1" && icacls "%1" /grant administrators:F"
"IsolatedCommand"="cmd.exe /c takeown /f "%1" && icacls "%1" /grant administrators:F"
[-HKEY_CLASSES_ROOTDirectoryshellrunas]
[HKEY_CLASSES_ROOTDirectoryshellrunas]
@="獲取超級管理員權限"
"Icon"="C:WindowsSystem32imageres.dll,-78"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOTDirectoryshellrunascommand]
@="cmd.exe /c takeown /f "%1" /r /d y && icacls "%1" /grant administrators:F /t"
"IsolatedCommand"="cmd.exe /c takeown /f "%1" /r /d y && icacls "%1" /grant administrators:F /t"
[-HKEY_CLASSES_ROOTdllfileshell]
[HKEY_CLASSES_ROOTdllfileshellrunas]
@="獲取超級管理員權限"
"HasLUAShield"=""
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOTdllfileshellrunascommand]
@="cmd.exe /c takeown /f "%1" && icacls "%1" /grant administrators:F"
"IsolatedCommand"="cmd.exe /c takeown /f "%1" && icacls "%1" /grant administrators:F"
[-HKEY_CLASSES_ROOTDriveshellrunas]
[HKEY_CLASSES_ROOTDriveshellrunas]
@="獲取超級管理員權限"
"Icon"="C:WindowsSystem32imageres.dll,-78"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOTDriveshellrunascommand]
@="cmd.exe /c takeown /f "%1" /r /d y && icacls "%1" /grant administrators:F /t"
"IsolatedCommand"="cmd.exe /c takeown /f "%1" /r /d y && icacls "%1" /grant administrators:F /t"
2、刪除管理員權限。復制代碼根據上面的步驟新建記事本粘貼到記事本中,另存為.reg格式,雙擊即可刪除管理員權限。
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT*shellrunas]
[-HKEY_CLASSES_ROOTDirectoryshellrunas]
[-HKEY_CLASSES_ROOTdllfileshell]
[-HKEY_CLASSES_ROOTDriveshellrunas]
[-HKEY_CLASSES_ROOTexefileshellrunas]
[HKEY_CLASSES_ROOTexefileshellrunas]
"HasLUAShield"=""
[HKEY_CLASSES_ROOTexefileshellrunascommand]
@=""%1" %*"
"IsolatedCommand"=""%1" %*"
通過注冊表來獲取Win8.1超級管理員權限的方法更為方便,雖然是需要修改注冊表,但我們采用的是導入注冊表的方式,用戶可以不用擔心注冊表修改錯誤。