Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Major upgrade deletes registry entries


1 reply to this topic

RickBart

RickBart
  • Members
  • 7 posts

Posted 01 March 2002 - 16:13

I have a project that sets a few registry entries in script, because I don't know the values at build time.  It works fine on the initial install, but when I create a major upgrade to that project and install it on top of the original version, it deletes the registry entries.  In my testing, I'm not actually making any changes in the script for the major upgrade.  I just followed the documentation on "Major Upgrades for Standard Projects."

I've put in display statements to verify that it is hitting my code on the upgrade installation and it sets the registry values correctly, but InstallShield deletes the entries at some point after that.

I've tried putting the code in OnFirstUIAfter, OnMoved, and OnEnd, but the end result is always the same.  I created a test installation that does nothing but set a single registry entry in script and duplicated the problem.  I've had an open call with InstallShield on this for over a week.

This doesn't seem like a very obscure thing to do, and I can't believe more people aren't running into it.  Has anyone else seen or solved this problem?


RickBart

RickBart
  • Members
  • 7 posts

Posted 01 March 2002 - 20:30

Well, I guess all I had to do is post the question here, and I get an answer.  InstallShield got back to me today with a solution that seems to be working.  Here's what they suggest:

1.  Define a property for each value that I want to set in the registry.
2.  Instead of creating registry entries in my script, I need to create them in a component.  Since I don't know the value for the registry entries at build time, I specify the value as my property name, enclosed in square brackets.
3.  Within the OnFirstUIBefore event, I use MsiSetProperty to update the property value.