Solved

Registry Change Via Logon Script

Posted on 2004-08-07
5
362 Views
Last Modified: 2010-04-14
I need to change the value of the default key in HKLM\Software\Microsoft\Windows\CurrentVersion\Run to blank via either my batch file script or my vbs script at logon for the computers in our domain. Some computer have a weird value that is causing the system32 window error at log in.  I have been trying a while and cant seem to find a command that works.  Thanks, Aaron
0
Comment
Question by:luders
  • 3
5 Comments
 
LVL 10

Expert Comment

by:dis1931
ID: 11742896
Delete values:

Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\Software\MyStuff]
"MyLittleValue"=-
"MyLittleValue2"=-

But if you need to delete entire key

Windows Registry Editor Version 5.00
[-HKEY_LOCAL_MACHINE\Software\MyStuff]

Place those what you need in a .reg file and run it.  

I would suggest going with deleting the entire Run key and then recreating it empty since you will not know all the values inside them.  Just be careful as people may have legitimate things in there such as Palm software, Antivirus software, etc....
0
 

Author Comment

by:luders
ID: 11742963
Okay I tried these options and no luck. I could delete the default value via reg edit which works just as well as changing the default value because it re creates the default value blank. But I could not do either via the scripting. The first option here creates a duplicate default value and the second does nothing. Ideas?

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run]
"(Default)" = " "

Windows Registry Editor Version 5.00

[-HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run\(Default)]
0
 

Author Comment

by:luders
ID: 11742967
Also, deleting the Run key seems no good because as you said there are other legitimate run commands.
0
 
LVL 14

Accepted Solution

by:
dlwyatt82 earned 500 total points
ID: 11742985
The reason for this is the "(Default)" value is referenced by @ in a .reg file. You need to do this:

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

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run]
@=-
0
 

Author Comment

by:luders
ID: 11743010
Thats what I am lookin for. Thanks, Aaron
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Windows 2000 Kerberos problem 5 321
Windows 2000  Domain controller 3 500
Restore SQL database from 8.0 to 11.00 ? 3 1,225
windows 2000 image 3 137
NTFS file system has been developed by Microsoft that is widely used by Windows NT operating system and its advanced versions. It is the mostly used over FAT file system as it provides superior features like reliability, security, storage, efficienc…
An article on effective troubleshooting
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question