registro vbscript

Edición rápida del registro

Cuantas veces hemos necesitado editar el registro... yo cada vez que tenia que hacer algún cambio lo hacía de formas distintas, usando WMI, ficheros .REG, etc....

Os dejo una forma simple, con cuatro líneas de código está terminado.

Espero que os sea útil.

  1. Option Explicit
  2. On Error Resume Next
  3.  
  4. Dim oShell, sRutaRegistro
  5.  
  6. sRutaRegistro = "HKLM\SOFTWARE\Microsoft\Windows NT\currentVersion\Winlogon\"
  7.  
  8. Set oShell = CreateObject("WScript.Shell")
  9.  
  10. oShell.RegWrite sRutaRegistro & "Shell", "explorer.exe", "REG_SZ"
  11.  
  12. Set oShell = Nothing

 páginas vistas.