cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
DataAnalyzer
Level 7

Upgrading a Product with a New Product Name Fails

We have a product "MyProduct Basic" that people install.

We create updates for the product and just change the version number in InstallShield, When the setup program is run, if it detects it's installed, it upgrades it. If not, it performs the full installation. Works great!

We created a new Product Configuration with a new name (e.g MyProduct Pro). We want that setup to be similar to the upgrade and the Basic version if it's already installed. Because the product name changed, that doesn't happen even though I have it using the same product GUID (or not). Neither works..

Is there a way to update the existing installation and change the name so it replaces the existing program on disk and in the Windows Control Panel Add/Remove Programs list?

Without that, we are forced to tell the user:

1. Uninstall the existing version and install the new one, or
2. Have our setup program keep the old program name (so Basic stays forever) which would confuse people if they go to the control panel list since the thought they own the Pro version. For new installations, it would say Basic when it should be Pro, so that's unacceptable.

Not sure what I'm missing to handle this. Thanks in advance.
.
Labels (1)
0 Kudos
15 Replies
Dan_Galender
Level 10

To change the product name, you'll want to create a Major Upgrade. Change the ProductName, change the ProductCode, change the ProductVersion, and author a Major Upgrade item in the Upgrades view.
0 Kudos
DataAnalyzer
Level 7

DanGalender wrote:
To change the product name, you'll want to create a Major Upgrade. Change the ProductName, change the ProductCode, change the ProductVersion, and author a Major Upgrade item in the Upgrades view.


Thanks. Glad to know it's possible. I must be misunderstanding something.

Where is the Major Upgrade Item? Is it under the Product Configuration or Releases? How do I link the two Product Configurations to each other?
0 Kudos
Dan_Galender
Level 10

Look in the Upgrades view (Between Path Variables and Releases) and read the topic "What is a Major Upgrade?"

If both versions were created by the same project, the linkage is done through the Upgrade Code.
0 Kudos
DataAnalyzer
Level 7

Thanks. I see the Upgrade code in the Media/Upgrades section.

How is that different from the Upgrade Code in the Releases?

Is there only one Upgrade code for all Releases or do I use the same Product Code and Upgrade Codes in the Releases (General tab) to tie them together?

And if so, does it need to be the same Upgrade Code as the one in the Upgrades page.

Thanks.
0 Kudos
Dan_Galender
Level 10

If you don't change it (and you shouldn't), The UpgradeCode will remain the same across all releases and versions of your projects. You use it in the Major Upgrade field so that the upgrade process can find older versions of your product that have been installed on a given machine when installing this version.
0 Kudos
DataAnalyzer
Level 7

Thank you. I've confirmed that we can get the setup to kick into upgrade mode by using the Upgrade Code, but it triggers an Error 1316: The specified account already exists.
Seems like I ran into this error 3 years ago when I tried this and discovered it was tied to changing the product name: https://community.flexerasoftware.com/showthread.php?219059-Error-1316-The-specified-account-already-exists

Not sure how to get around since we need to change the product name.

That said, maybe this other issue can fix that. When a Major Upgrade occurs, we need to run the code we currently have in the OnFirstUIBefore function. We have code to prompt the user to enter their new Serial Number that we need to validate for the upgrade. That function is skipped during an update. Can we set something so that it's run only for new installations and Major Upgrades?
0 Kudos
Dan_Galender
Level 10

Did you change the ProductCode in the project when you changed the product's name?
0 Kudos
DataAnalyzer
Level 7

The product configuration has a Product Code GUID for the new release that is the same as the Product Code for the previous version. But the names are different.
0 Kudos
Dan_Galender
Level 10

Please read that topic I referred you to "What is a major upgrade?" in the Upgrades view. The first sentence under the heading "How do you get a major upgrade to work?" states that the ProductCode must be changed for a major upgrade to work (emphasis mine). Changing the product's name is permitted in a major upgrade, but not necessary. Changing the ProductCode is necessary.
0 Kudos
DataAnalyzer
Level 7

Thanks. Sorry for not picking up on that. We'll go ahead and try that.

How about running the OnFirstUIBefore function during the Major Upgrade?
0 Kudos
Dan_Galender
Level 10

What project type is this?
0 Kudos
DataAnalyzer
Level 7

This is an MSI project. It installs a Windows program.

I created a new build with a different product code but same Upgrade Code as the previous installation. For whatever reason, the Upgrade Code GUID was already defined for the version we've already released. When the setup program ran, it treated it like a new product rather than trying to upgrade it.
0 Kudos
Dan_Galender
Level 10

Yes, unless you change the UpgradeCode (which you should not do), the project will remain the same as you continue to upgrade the product that your installer installs.

Basic MSI projects do not run the events like "OnFirstUIBefore".

What a major upgrade does is to implicitly uninstall the old version and then installs the newer version, so yes, it presents the same user interface as a first-time installation--that's how it upgrades existing versions of your product on those computers. This type of upgrade is the only one that will allow you to change the product's name. I can't urge you strongly enough to very carefully read the entire topic I've referred to several times now called "What is a major upgrade?". In it it says, in part, that a major upgrade will look the same as a fresh installation when run on a system with an earlier version installed on it. It then goes on to explain the uninstallation process that a major upgrade implicitly performs.
0 Kudos
DataAnalyzer
Level 7

I'm not sure what a "Basic" MSI project is. I use an ISM file and it has the OnFirstUIBefore event.

I've read and re-read the "What is a major upgrade?" section and still can't seem to get it to work.

When I keep the same Upgrade Code and change the Product Code, the installation runs, but it installs but doesn't uninstall the previous version.
If I keep the same Product Code, it triggers the Error 1316 I mentioned earlier.

Are there any sample ISM files I can use to see how it works?

I'm stuck with a situation where the existing Product Configuration already has a product and upgrade GUID that I presume overrides the values at the General Information level. So when I'm setting those values, I'm doing it at the Product Configuration, not overall General Information section. Should I change something at that level?

Thanks in advance for your patience with me.
0 Kudos
Georg1
Level 4

As I understand your old product has some features and these are installed after the upgrade but shouldn't - that's why you think it's not uninstalled?

This might be related to the changed product code. Dan already descriped the behaviour but is missing one point I think. In case of the major upgrade the installer trys to migrate the feature states of the old installation. As long as this is possible the previously installed features are re-installed - so in case of a custom installation where the user picks specific features these are installed without the need to select them again. This means it is not exactly uninstall and new install.
With our setup we had the issue this doesn't work and the user was forced to select the features again after a major upgrade. This was caused through "breaking changes" which caused the migration of old feature states to fail and then you have a full uninstall and new install with all the dialogs involved.
In our case we removed old components from the installation. If you can't do that, change or remove a feature name which existed in the old installation should have the same effect.
Perhaps try something along those lines.
0 Kudos