Solved

Registry Change Via Logon Script

Posted on 2004-08-07
5
364 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

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

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…
A lot of things can happen during a presentation, worst of which is “death by PowerPoint.” Here are a few mistakes to avoid to make your slides clean.
Suggested Courses

739 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