how to make a reg file to automatically delete a string valu
Here's the thing. When i install autocad 2002 and i take a look in the add/remove program window, all the programs coming after autocad are placed waaaaaaaaaaaaaaay below the autocad entry. I mean there's a gap of 20 cm's.
Here's the thing. When i install autocad 2002 and i take a look in the add/remove program window, all the programs coming after autocad are placed waaaaaaaaaaaaaaay below the autocad entry. I mean there's a gap of 20 cm's.
I found a key in the registry to be the cause. When i delete that key everything is fine.
My question is: is it possible to make a reg file that will delete this key when i double click on it? So after a format i don't have to go into HKLM --> software --> microsoft --> windows --> currentversion --> uninstall (or something like that) just to remove that key. (it's a string value, if that matters)
Thanks
[edit]
Here's some more details. i exported the key to a reg file:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{5783F2D7-0101-0409-0000-0060B0CE6BBA}]
"DisplayIcon"="C:\\Program Files\\AutoCAD 2002\\acad.exe,-1"
The problem is it tries to display an icon in the add/remove programs window, but fails, which makes a gap appear between that progam and the rest of the list.
I found a key in the registry to be the cause. When i delete that key everything is fine.
My question is: is it possible to make a reg file that will delete this key when i double click on it? So after a format i don't have to go into HKLM --> software --> microsoft --> windows --> currentversion --> uninstall (or something like that) just to remove that key. (it's a string value, if that matters)
Thanks
[edit]
Here's some more details. i exported the key to a reg file:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{5783F2D7-0101-0409-0000-0060B0CE6BBA}]
"DisplayIcon"="C:\\Program Files\\AutoCAD 2002\\acad.exe,-1"
The problem is it tries to display an icon in the add/remove programs window, but fails, which makes a gap appear between that progam and the rest of the list.
Participate on our website and join the conversation
This topic is archived. New comments cannot be posted and votes cannot be cast.
Responses to this topic
Here's some examples from the registry files I added to an affinity program to add right-click functionality to pick which processor you wish to run the executable on!:
INSTALL
[HKEY_CLASSES_ROOT\exefile\shell\Affinity1]
@="Use CPU 1"
UNINSTALL
[-HKEY_CLASSES_ROOT\exefile\shell\Affinity1]
@="Use CPU 1"
See the difference?
INSTALL
[HKEY_CLASSES_ROOT\exefile\shell\Affinity1]
@="Use CPU 1"
UNINSTALL
[-HKEY_CLASSES_ROOT\exefile\shell\Affinity1]
@="Use CPU 1"
See the difference?
The problem is, some [many] programs will respond differently to an empty value as opposed to a non-existant value.
If I read a REG_SZ from the registry and it's simply not there, the API call will respond differently than if I read it and it's been set to an empty string.
In the former case, I might use a default value -- but I probably won't put in a check to see if it's merely empty (it's reasonable to assume that if the value exists then it's meaningful, no?).
If the intent is to delete, then you should make certain to delete.
If I read a REG_SZ from the registry and it's simply not there, the API call will respond differently than if I read it and it's been set to an empty string.
In the former case, I might use a default value -- but I probably won't put in a check to see if it's merely empty (it's reasonable to assume that if the value exists then it's meaningful, no?).
If the intent is to delete, then you should make certain to delete.