Enable Your Registry

View previous topic View next topic Go down

Enable Your Registry

Post  adnanbahrian on Sun Apr 19, 2009 11:14 am

In notepad, copy/paste the following script, and save the file with a .vbs extension, then run it :

'Enable/Disable Registry Editing tools
'© Doug Knox - rev 12/06/99
'This code may be freely distributed/modified as long as it remains free of charge
'Edited by PatheticCockroach - http://patheticcockroach.com

Option Explicit
'Declare variables
Dim WSHShell, rr, rr2, MyBox, val, val2, ttl, toggle
Dim jobfunc, itemtype

On Error Resume Next

Set WSHShell = WScript.CreateObject("WScript.Shell")
val = "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System\DisableRegistryTools"
val2 = "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System\DisableRegistryTools"
itemtype = "REG_DWORD"
jobfunc = "Registry Editing Tools are now "
ttl = "Result"

'reads the registry key value.
rr = WSHShell.RegRead (val)
rr2 = WSHShell.RegRead (val2)

If (rr=1 or rr2=1) Then toggle=0

If toggle = 1 Then
WSHShell.RegWrite val, 1, itemtype
WSHShell.RegWrite val2, 1, itemtype
Mybox = MsgBox(jobfunc & "disabled.", 4096, ttl)
WSHShell.RegDelete val
WSHShell.RegDelete val2
Mybox = MsgBox(jobfunc & "enabled.", 4096, ttl)
End If

Posts : 262
Join date : 2009-02-24

View user profile http://apnadas.forumotion.com

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

Permissions in this forum:
You cannot reply to topics in this forum