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
- :
- Installshield registry bug found - Properties show up as literals in registry
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
‎Jan 20, 2011
01:23 PM
Installshield registry bug found - Properties show up as literals in registry
Sorry if this isn't the correct place to post this.
I have found an annoying bug pertaining to registry values in IS. I'm working with a basic msi project and I've had this bug happen twice so far.
I have two features (Feat1, Feat2) with registry entries in each. I want to copy a particular registry key from Feat1 to Feat2, so I right-click on the key and select "export selected branch..", then paste it to the registry in Feat2. Feat2's registry had existing keys with properties as values prior to the copy, ie: [INSTALLDIR], [REGUSER]. When I build the install, run it and look at the computer's registry, the key's values from Feat2 are going to have the property's string literals instead of the value.
To solve this issue I open the project, delete the values of each key this is happening to, save the project, then manually type in the properties.
I have found an annoying bug pertaining to registry values in IS. I'm working with a basic msi project and I've had this bug happen twice so far.
I have two features (Feat1, Feat2) with registry entries in each. I want to copy a particular registry key from Feat1 to Feat2, so I right-click on the key and select "export selected branch..", then paste it to the registry in Feat2. Feat2's registry had existing keys with properties as values prior to the copy, ie: [INSTALLDIR], [REGUSER]. When I build the install, run it and look at the computer's registry, the key's values from Feat2 are going to have the property's string literals instead of the value.
To solve this issue I open the project, delete the values of each key this is happening to, save the project, then manually type in the properties.
(9) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 27, 2011
12:41 PM
I also ran into this problem with my basic MSI and Installscript-MSI projects when I imported .reg files with properties.
I found that looking at the registry values in the Direct Editor (Registry table), all the "[" and "]" characters from those imported keys had some kind of escape characters added in front of them (I forget the exact characters now). Deleting those characters fixes the registry keys (without needing to completely re-enter the rest of the value contents).
I found that looking at the registry values in the Direct Editor (Registry table), all the "[" and "]" characters from those imported keys had some kind of escape characters added in front of them (I forget the exact characters now). Deleting those characters fixes the registry keys (without needing to completely re-enter the rest of the value contents).
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 27, 2011
12:45 PM
The first time this happened to me I looked in the direct editor at the registry entries and they had double brackets on each of the properties, [[property]]. So, removing the extra brackets solved it for me that time. However, the second time it happened to me everything looked fine in the direct editor, so I had to remove them all and manually add them again.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 27, 2011
01:43 PM
Here's an example of the value I would get after importing a key:
[\[]CommonAppDataFolder[\]]TheRestOfMyPath
This is with an IS-MSI project, using 2011 Premier Edition. Maybe the bug is different in other IS product editions?
Anyway, just to clarify for anyone else facing this, I needed to remove the \[] at the beginning of the property and the [\] at the end of the property.
[\[]CommonAppDataFolder[\]]TheRestOfMyPath
This is with an IS-MSI project, using 2011 Premier Edition. Maybe the bug is different in other IS product editions?
Anyway, just to clarify for anyone else facing this, I needed to remove the \[] at the beginning of the property and the [\] at the end of the property.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 27, 2011
01:44 PM
Yeah, that looks familiar. That's exactly what I had gotten the first time.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 31, 2011
08:29 AM
[\[]CommonAppDataFolder[\]]TheRestOfMyPath
This is with an IS-MSI project, using 2011 Premier Edition. Maybe the bug is different in other IS product editions?
Not sure I would call this a bug. .reg files know nothing about properties. So if you import a .reg file that has a string in it like [something] , InstallShield thinks you want to write that extact string to the registry, inlcuding the square brackets.
To do this - and to make sure the string with square brackets is interreted as a property by Windows Installer - it has to escape the brackets. Windows Installer's escape scheme is: Precede the special character with a backslash and then enclose the wholöe thing in square brackets. So if you want to escape # it would look like: [\#]. In case of a [ it becomes [\[] and for ] it becomes [\]]
Stefan Krueger
InstallSite.org
InstallSite.org
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 31, 2011
04:17 PM
I believe Hotfix A includes a fix for this; please check for updates if you haven't already. The round trip is the best argument (the number of you who used this behavior was similarly important) I've seen for why this is a bug instead of a debate about what .reg files should or should not know about, although the .reg argument Stefan mentions was why the change was attempted.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 02, 2011
11:11 AM
Yes, round trip is indeed a very good point.
Stefan Krueger
InstallSite.org
InstallSite.org
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 28, 2012
09:05 AM
Maybe a silly question but I have the opposite problem of I need this value in the registy [Common] Prod (SaaS) and it completly strips out the [Common] and leaves the rest.
What do I need to place around the brackets so when the app installs the brackets are in the registry?
Thank you!
What do I need to place around the brackets so when the app installs the brackets are in the registry?
Thank you!
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 28, 2012
10:58 AM
Sorry I answered my own question by doing this: [\[]Common[\]]Prod (SaaS)