Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Deleting Registry Keys

Status
Not open for further replies.

DDLee

Programmer
Nov 8, 2001
1
US
I'm trying to write a script to delete the registry keys for Outlook Express in Windows 2000. I need to do this on about 100 computers. Everything I've read says I can do this, but I'm having major problems. Anyone have any suggestions and/or script samples?

Thanks.
 
I am very much aware of how to do this. I have had the same problems... I am unaware of how to do this through VB but you can easily do this with some resource kit utils and a good bat script. I would sugguest you look into regini.exe. You can download this file and the instruction set from Microsoft I believe.. or I can send it to you if you wish.. in addition I could provide you with some sample scripts that we have written that would make use of this if you wish...

You may get me at KAHenderson@firstfleetinc.com

Hope this helps.

Austin Henderson
Network Administrator
FirstFleet, Inc.
 
U can use the WScript object:

Code:
set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.RegWrite "HKCU\Software\ACME\FortuneTeller\", 1, "REG_BINARY"
WshShell.RegWrite "HKCU\Software\ACME\FortuneTeller\MindReader", "Goocher!", "REG_SZ"

WshShell.RegDelete "HKCU\Software\ACME\FortuneTeller\MindReader"
WshShell.RegDelete "HKCU\Software\ACME\FortuneTeller\"
WshShell.RegDelete "HKCU\Software\ACME\"

Hope this helps. Form me works just fine...
________
George, M
 
Remove the "WScript." from the WScript.CreateObject("WScript.Shell") line... ________
George, M
 
Okay - Even I can do that part, but now something that bugs me: How to do the same trick to remote computers registry running the code locally?

Actually I'd like to retrieve some values from remote computers registry key like
"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\CSDVersion" that has a string value containing service pack version info.
The registry value goes both w2k & Nt4.

Any kind of suggestions?
Thanks

Beware - it's soon christmas and satan claus in on the road
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top