Dim WshShell Set WshShell = WScript.CreateObject("WScript.Shell") On Error Resume Next WshShell.RegDelete "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System\DisableRegistryTools" WshShell.RegDelete "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System\DisableRegistryTools"