- NSIS Discussion
- Writing component names to registry
Archive: Writing component names to registry
watzr
28th September 2009 05:33 UTC
Writing component names to registry
Hi,
I wanna keep track of all the components I've installed by writing them to registry. I didn't find any entry name to write those values. Is it ok to write those names as a single string to "DisplayName" at Uninstallation Information?
MSG
28th September 2009 08:35 UTC
Why not just create your own registry key? HKCU\Software\YourCompany\YourApp would be a logical place to put this...
watzr
28th September 2009 10:40 UTC
Thanx...
watzr
30th October 2009 06:15 UTC
Hi MSG,
I have created a registry key in Current User as mentioned above and it worked as I wanted. But now I wanna make sure if I created this new entry in Local Machine instead of Current User, will it make any problem. I'm keeping installation information since they are used for patch installation. In this case they might be necessary for some other users if they are going to install patch files. so which is the best place to create a registry entry in this case..
MSG
30th October 2009 09:19 UTC
Sure, you can use HKLM if you prefer that. The only problem is that the installer will need admin priviledges for that.
watzr
30th October 2009 09:34 UTC
Is there any deference between adding an entry to "Software\Microsoft\Windows\CurrentVersion\App Paths\" and to somewhere else in Local Machine (say "MyApp\")..
Anders
30th October 2009 10:38 UTC
App Paths is sort of special, it is used by windows and it is also harder to make unique ("app.exe" vs "company\app")
watzr
2nd November 2009 17:05 UTC
Does the use of APP PATH instead of user defined entry eliminate any configuration errors? Is there a relationship between environment variables and APP PATH?
Anders
2nd November 2009 17:56 UTC
What does "configuration errors" have to do with storing component names?
Anyways, the "" (default) value is used by ShellExecute when starting programs without full paths, and the path value is added to the programs path environment variable.
watzr
3rd November 2009 03:24 UTC
If I created my own entry in Local Machine (Say HKLM\MyAPP) then does ShellExecute use the default value?
I wanna know whether this is a standard entry that we should use or can we create our own place. Doesn't "Software\Microsoft\Windows\CurrentVersion\" make sense that the product comes under Microsoft. (May be a silly question)
MSG
3rd November 2009 10:01 UTC
Stay away from CurrentVersion.
I'm not sure what the AppPaths regkey is for, but I do know it's not for writing your random installer-related regvalues to.
If you want to do it the proper way, use hklm\yourcompany\yourapp for all-user installs, or hkcu\yourcompany\yourapp for single-user installs. That's all there's to it.
watzr
3rd November 2009 10:46 UTC
Yup... I found that "Software\Microsoft\Windows\CurrentVersion\App Paths\" is to run the application by typing it in Run dialog box.
http://www.sandon.it/?q=node/24
Thanks for everyone.