zoukankan      html  css  js  c++  java
  • Windows7恢复右键 管理员取得所有权限

    把下面的代码保存为 admin.reg 保存后双击导入注册表即可!


    -------------------------------------------------------------------------------------


    Windows Registry Editor Version 5.00




    [HKEY_CLASSES_ROOT\*\shell\runas]
    @="管理员取得所有权"
    "NoWorkingDirectory"=""


    [HKEY_CLASSES_ROOT\*\shell\runas\command]
    @="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_ROOT\exefile\shell\runas2]
    @="管理员取得所有权"
    "NoWorkingDirectory"=""


    [HKEY_CLASSES_ROOT\exefile\shell\runas2\command]
    @="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_ROOT\Directory\shell\runas]
    @="管理员取得所有权"
    "NoWorkingDirectory"=""


    [HKEY_CLASSES_ROOT\Directory\shell\runas\command]
    @="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"Windows Registry Editor Version 5.00




    [HKEY_CLASSES_ROOT\*\shell\runas]
    @="管理员取得所有权"
    "NoWorkingDirectory"=""


    [HKEY_CLASSES_ROOT\*\shell\runas\command]
    @="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_ROOT\exefile\shell\runas2]
    @="管理员取得所有权"
    "NoWorkingDirectory"=""


    [HKEY_CLASSES_ROOT\exefile\shell\runas2\command]
    @="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_ROOT\Directory\shell\runas]
    @="管理员取得所有权"
    "NoWorkingDirectory"=""


    [HKEY_CLASSES_ROOT\Directory\shell\runas\command]
    @="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"



    REFERENCES:http://apps.hi.baidu.com/share/detail/20344530


    ---------------------------------------------------------------------------------------------------------------------------------
    copyright:http://www.cnblogs.com/anee/
  • 相关阅读:
    firstResponder
    形而上学
    du -h
    数据本地存贮与数据结构(对象)
    RFC
    oc语言源代码
    HTTP1.1协议中文版-RFC2616
    如何提高团队协作的效率
    iOS应用架构谈 开篇
    nginx版本如何选择?
  • 原文地址:https://www.cnblogs.com/anee/p/2675737.html
Copyright © 2011-2022 走看看