This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: Unique Registry Keys for Multi-Instance InstallScript
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎May 07, 2008
03:44 PM
Unique Registry Keys for Multi-Instance InstallScript
I inherited an InstallScript project and I've been tasked with adding a number of additional features and am so close to having what I need. The project was originally single instance and one of the new requirements is that it be multi-instance.
During the install certain registry keys are created in HKCR. These keys seem to be only needed for upgrade and uninstall purposes. However, since this was not originally designed as multi-instance architecture, it simply creates the keys and overwrites them at each subsequent install. Then when you go to uninstall, for example, it removes things its not supposed to based on those keys.
Example:
I've seen references to szUninstallKey and tried creating the values in there since each instance gets its own unique key, however my InstallScript doesn't recognize szUninstallKey as a defined variable.
It doesn't really matter where the keys are located. How do I create a set of registry keys that is unique for each instance, and how do I reference those values in an InstallScript?
Thanks in advance!
During the install certain registry keys are created in HKCR. These keys seem to be only needed for upgrade and uninstall purposes. However, since this was not originally designed as multi-instance architecture, it simply creates the keys and overwrites them at each subsequent install. Then when you go to uninstall, for example, it removes things its not supposed to based on those keys.
Example:
1st Install:
2nd Install:
Uninstalling the 1st Instance (Training) causes parts of "Production" to be uninstalled!
HKCR\KeyA = Training
2nd Install:
HKCR\KeyA = Production
Uninstalling the 1st Instance (Training) causes parts of "Production" to be uninstalled!
I've seen references to szUninstallKey and tried creating the values in there since each instance gets its own unique key, however my InstallScript doesn't recognize szUninstallKey as a defined variable.
It doesn't really matter where the keys are located. How do I create a set of registry keys that is unique for each instance, and how do I reference those values in an InstallScript?
Thanks in advance!
(2) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎May 07, 2008
04:26 PM
The InstallScript variable INSTANCE_GUID contains a unique ID for each instance, so perhaps incorporate that into each instance's registry data?
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎May 08, 2008
08:22 AM
That is exactly what I needed. THANKS!