Join us for SoftSummit 2023. The 20th anniversary of the industry leading software monetization conference. April 18 and 20. Register Now

Showing results for 
Show  only  | Search instead for 
Did you mean: 
Level 2

Clarification of a couple things for a new user


I am working with an evaluation version of Installshield 2011 for a couple days so far, but I have a few questions that need a quick answer since I am being asked and could use some more experienced feedback. I will be going through the Sticky's and other postings but a direct answer to some of these questions would be helpful. I have done some checking around, but there are so many different tutorials and versions that the confusion has forced me to try this.

I've been asked to build a simple installer for an application that is undergoing some changes. The previous MSI installer was built with an old version of Wise. It had no install options (ie: no feature selection, no path choices etc.), no maintenance on second run - only an uninstall. The updates to the software probably should be considered a major update, but the increment given indicates a minor (from 1.4 to 1.5). There are some additional components among other things to be included in the new package. This installer had a couple of issues, for example it did not prevent downgrades and it may have shared a product code in addition to upgrade code for a couple releases.

Since installshield is the new tool to be used for this project (MSI Installscript), and it will be an all new setup my aim will be to first detect anything currently installed with the same upgrade code and completely uninstall it. Based on what I've read so far, I will outline a couple possible approaches I am considering, and would appreciate any fair warning if they are impossible or impractical. Better methods will obviously be welcome.

If I have to use 1.5 as the release version, as I understand it this is not considered a major upgrade and installshield will not uninstall the previous version, or am I wrong?. Is there any way this can be overridden? I have been looking at some installscript commands like uninstallapplication, and I can see how this could be used with a product code but I don't know how to target generically the upgrade code family with installscript. I assume such a command could be placed in OnBegin()? I could use product codes if I have to, and check the registry to see if they are there, then try an uninstall. Is this reasonable?

If we could bump the release number to 2.0, and consider it a major release, I suspect there is a way to automate the uninstall method. In the installation designer tab under media->upgrades, there is a default item called ISPreventDowngrade. I presume I would have to add another item like this here (like ISFoundRelated) to make the previously installed criteria available to the installer? Is anything else required in addition to making this entry? I'd appreciate an explanation on how this works or what else is needed. In particular the detect setting is confusing. If it as simple as this item making an entry into the upgrade table and I'm done, this is probably the route to take. If it requires other steps I'm not sure what they are. You're probably wondering why don't I try it and find out, well I did but did not get a proper cleanup so I think there is something missing. The new installer will share only the upgrade code with previous versions, regardless of which version number we choose to go with.

For the dialogs, since I will be disabling maintenance I assume I can place the needed prompts in OnFirstIUBefore and OnFirstUIAfter, which I assume will override the default dialogs. I need an after copy event to make a change to a config file.

Thanks for taking the time to read this. I appreciate any comments. I am not an expert on this, but I will respond as best I can.

best regards, et
Labels (1)
0 Kudos
1 Reply
Level 2

Another approach that might work (seems promising in a couple tests) would be to create a major upgrade item that applies the upgrade code to "Any earlier version", excluding the maximum version and set to detect only. This would be practically the same as the ISPreventDowngrade item. In custom actions I create a new custom action error message which is placed after FindRelatedProducts (Installation UI and execute) and has as condition the detect property from the new upgrade item. This aborts the installer when condition is met and seems to work regardless of what product version number I currently have. This wouldn't be a bad solution, it will force the user to the control panel to remove the earlier version if detetcted.
0 Kudos