mhatkinson
Posts: 32
Joined: Tue Apr 08, 2008 5:36 pm

UpgradeCode and installing new versions

I have an older version of our product installed (one whose installer wasn't made with AdvancedInstaller) and I'd like our newer version of the same product to detect that the older one is installed and then remove the old version.

The old products version is 2.0.3 and the new one's is 2.1.0
The installer for the new version has the same UpgradeCode as the old one and the Upgrades page looks something like this (excuse the formatting):

Upgrade Code Min. Ver Max. Ver. Property
{60E0C...} [|ProductVersion] PREVIOUSVERSIONSINSTALLED
{60E0C...} [|ProductVersion] NEWERPRODUCTFOUND

Additionally, I notice that if I click the 'Customize Advanced Installer...' checkbox, there's a couple more Upgrades with the properties AI_NEWERPRODUCTFOUND and OLDPRODUCTS.

However, when I run the newer installer I always end up with 2 versions of the product in the Windows Add/Remove programs dialog. Is there anything I might be missing? Or do I need to specifically define the properties (eg: NWERPRODUCTFOUND)?

Thanks,
Mark
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: UpgradeCode and installing new versions

Hi,

In order to upgrade another MSI package you can simply add it in the Upgrades page (without using the "Customize Advanced Installer upgrade rules" option). This way the package will silently remove the old product before the installation.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
mhatkinson
Posts: 32
Joined: Tue Apr 08, 2008 5:36 pm

Re: UpgradeCode and installing new versions

cosmin wrote:
In order to upgrade another MSI package you can simply add it in the Upgrades page (without using the "Customize Advanced Installer upgrade rules" option). This way the package will silently remove the old product before the installation.
That's what I'm doing. And it seems to work with different installer versions created with Advanced Installer. But I have an older version and it doesn't seem to work for that one even though it has the same UpgradeCode as the Advanced Installer versions.
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: UpgradeCode and installing new versions

Hi,

Can you please give me more details about the problem you are encountering? What exactly is the behavior when you launch the upgrade package on a machine which contains the old installation?

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
mhatkinson
Posts: 32
Joined: Tue Apr 08, 2008 5:36 pm

Re: UpgradeCode and installing new versions

cosmin wrote:
Can you please give me more details about the problem you are encountering? What exactly is the behavior when you launch the upgrade package on a machine which contains the old installation?
Hi,
Thanks for the quick responses on this!
When I install the new version it goes through the same process as if there were no older version of the product installed. Everything goes fine, but when I view installed software using Add/remove programs there are 2 versions our product installed - the old and the new. The installation of the new version doesn't detect the old version.
I know they have the same upgrade code but I can't figure out what difference might stop the detection of the old version.
Could it be if the difference of whether it was installed for AllUsers vs. Single User ?
mhatkinson
Posts: 32
Joined: Tue Apr 08, 2008 5:36 pm

Re: UpgradeCode and installing new versions

Yeah, that's it. Our old version was installed for the single user and the new version is installed for all users. When I change the new version to install for a single user then it detects and removes the old version.

So, is there a way to detect old versions even though the Installation Type might be different?

thanks,
Mark
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: UpgradeCode and installing new versions

Hi,

Please note that Windows Installer doesn't support upgrading a per-user installation with a per-machine package or a per-machine installation with a per-user package. You can find more information about Windows Installer major upgrades on MSDN.com.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”