PDA

View Full Version : Minor Upgrade Problem



anthdale
12-04-2003, 05:12 PM
I having a problem with a minor upgrade that I hope someone knows how to solve. When I use the OnResumeUIBefore and OnResumeUIAfter functions with my minor upgrade, it works fine if the original setup has been installed first. However, when I run my minor upgrade without the original setup installed, it will not call those functions (that does makes sense based on the function names). However, is there a custom action or any setting that I can do to include those script functions if the upgrade is performed without the original setup installed? My current Minor Upgrade command line is set to REINSTALLMODE=voums REINSTALL=ALL.

Thanks!

lsmeteor
12-04-2003, 05:35 PM
I think you are missing some custom action to reset the REINSTALLMODE and REINSTALL properties for a first time installation
You want to set both to {} (nothing)

If you absolutely want to use the script functions, you'll have to move them out of their current location so that you can call them from anywhere. You can call them from custom actions as well.

take a look at this thread: http://community.installshield.com/showthread.php?s=&threadid=107134

There is a pretty good check list for minor upgrades. Works well. You can then develop your logic to call your script functions following the list logic.

anthdale
12-05-2003, 08:27 AM
Thank you for the response, however I have already referenced that thread and configured my install accordingly. I have custom actions REINSTALLMODE AND REINSTALL set to {}. In addition, moving the upgrade functions out of their current location so that I can call them anywhere in the script will not work either. I have tried that and it appears that it uses the original script when the install has never been performed on the box I am installing my setup. What I am wanting to do is (1) run the minor upgrade to upgrade a box with the original setup already on the box, therefore only upgrading the changes or (2) run the minor upgrade to install the original setup with the changes (including the script) on a box that does not contain the original setup already. It works great except for running the script in scenario number 2. Again, thanks for your response!

lsmeteor
12-05-2003, 09:53 AM
When you say that the package uses the original script when installing on a box that was never installed on, do you mean it is performing a fresh installation?

Can your setup perform either one (fresh install or minor upgrade)?

If this is the case, you also need to alter the fresh install logic to make it do what you want.

I would find it very odd in the case that you make modification to a script, then perform an upgrade with the package still using the original script. I just changed the script in one of my projects to take into account a new parameter. The upgrade does as it is supposed to (for now) and doesn't use the original script.

anthdale
12-05-2003, 10:28 AM
Yes, I mean it is performing a fresh installation. Yes, my minor upgrade can perform a fresh upgrade including the minor update components or just a minor upgrade with only the new components. I am trying to be proactive in preparing for upgrades before my release because I have been burned by InstallShield before. I am currently coding the logic into my "fresh" install script to check and see if it is an original or not. If it is an original setup then I will set a boolean variable to true in which I will try and launch the OnResumeUIBefore and OnResumeUIAfter functions at the end if my script. These functions will remain empty until I need them. I have no idea if this will work. I was just hoping that there was a cleaner way to do this. It seems that if it is able to recognize the new components for a minor upgrade performing a fresh install it should recognize the added script as well. In addition, I believe it is using the original script because I specify in my Release the previous package msi so that this will work in the first place. I appreciate your help.