Unable to Deinstall with newer MSI, another version of this product is installed - Advanced Installer Community
PascalQuenteux
Posts: 14
Joined: Mon Jul 22, 2024 1:56 pm

Unable to Deinstall with newer MSI, another version of this product is installed

Unable to Deinstall with newer MSI, another version of this product is installed


Hello,
So when I install a msi/exe setup. Run a new Build, change the msi/exe file and try to deinstall with the msi/exe. I get the following error.

Image

The setup is complete and will not change anymore “except for the binaries,” so the uninstallation should actually work with the existing rules.
"Is only one Exe called with --install or --uninstall" this will never change only the file in the msi/exe.

Usecase: A Customer install our setup e.g. 20.06.25 and will uninstall with a new msi/exe on 21.06.25.
It should be possible to uninsall with every new msi/exe build further on. Our usecase will remain the same.

Is it possible to configure this in the AIP, and if so, how?

Thanks for any help.
Attachments
image.png
image.png (52.5 KiB) Viewed 3244 times
Catalin
Posts: 7847
Joined: Wed Jun 13, 2018 7:49 am

Re: Unable to Deinstall with newer MSI, another version of this product is installed

Hello Pascal,

That error is usually encountered because you haven't changed the ProductCode.
Screenshot_70.png
Screenshot_70.png (23.53 KiB) Viewed 3238 times

When you change the version (i.e. increase it) and try to build the project or move to a new page, you are asked if you want to change the ProductCode, to which you should say "Yes".
Screenshot_71.png
Screenshot_71.png (11.64 KiB) Viewed 3238 times

If you clicked "No" by mistake there, you can manually change the ProductCode by going to "ProductDetails" page --> "Product IDs" tab.
Screenshot_72.png
Screenshot_72.png (11.21 KiB) Viewed 3238 times

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
PascalQuenteux
Posts: 14
Joined: Mon Jul 22, 2024 1:56 pm

Re: Unable to Deinstall with newer MSI, another version of this product is installed

Thx for your reply.
After we change that the ProductCode. The msi/exe try to install over the installed product.
We also diabeld the setting "Allow side by side installs" and "Unintall old, version first". The changeing of the ProductCode didnt work as we expected.

As mentions above we need the same behaviour as we have with ever new msi/exe, that we enter the uninstall routine with every new setup which was isntalled with an old setup.
image.png
image.png (16.66 KiB) Viewed 3233 times
Catalin
Posts: 7847
Joined: Wed Jun 13, 2018 7:49 am

Re: Unable to Deinstall with newer MSI, another version of this product is installed

Hello Pascal,
After we change that the ProductCode. The msi/exe try to install over the installed product.
Please note that this is the expected behavior.

If you increase the version and change the ProductCode, the new version will automatically detect and uninstall the old version before proceeding with the install of the newer version.

Isn't this what you want? If not, please explain to me what you would like the newer version to do so I can guide you in the right direction.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
PascalQuenteux
Posts: 14
Joined: Mon Jul 22, 2024 1:56 pm

Re: Unable to Deinstall with newer MSI, another version of this product is installed

That is not the current behavior. No uninstallation is offered. A normal installation opens in our case: select language, destination, and then it is installed. Even if a setup installation has already been completed.
PascalQuenteux
Posts: 14
Joined: Mon Jul 22, 2024 1:56 pm

Re: Unable to Deinstall with newer MSI, another version of this product is installed

After using the new setup, we want an UNINSTALL dialog, just like when you run the setup for the second time that you used to install it.
Screenshot 2025-09-18 132614.png
Screenshot 2025-09-18 132614.png (98.22 KiB) Viewed 3208 times
Catalin
Posts: 7847
Joined: Wed Jun 13, 2018 7:49 am

Re: Unable to Deinstall with newer MSI, another version of this product is installed

Hello Pascal,

Please note that what you see is the correct behavior.

What you want to happen is called "Maintenance Mode" and is only meant for the removal or modificaiton of a package.

On the machine, when you launch the same package after installation, the OS will check its' ProductCode and version and will see that those are the same and will proceed with the Maintenance Mode. Here, the user can, for example, install some more features that were initially missed (or simply not needed) during the first-time install. Additionally, the user can perform a repair (if the user, for example, accidentally removed a file) or simply uninstall the product.

An upgrade is meant to be smooth an remove the previous version automatically, which happens in your case.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
PascalQuenteux
Posts: 14
Joined: Mon Jul 22, 2024 1:56 pm

Re: Unable to Deinstall with newer MSI, another version of this product is installed

yes we want the "Maintenance Mode" with the new Build.

1) build a MSI
2) install the MSI
3) delete the MSI
4) build new msi with newer Version and ProductCode
5) start new MSI and get the "Maintenance Mode"

acually behaviour ist that MSI start a new Installation and not the "Maintenance Mode"
Liviu
Posts: 1419
Joined: Tue Jul 13, 2021 11:29 am
Contact: Website

Re: Unable to Deinstall with newer MSI, another version of this product is installed

Hello,

The Maintenance dialogs are displayed when you run for the second time your setup or when you click on the "Change" button on the Control Panel. The dialogs defined under the Maintenance section can appear only during the maintenance process (repair, modify or uninstall mode).
4) build new msi with newer Version and ProductCode
5) start new MSI and get the "Maintenance Mode"
I'm afraid this is not possible. The maintenance dialog is displayed only for the current setup as explained above. If you rebuild the project It either goes to the maintenance mode or displays the "Another version of this product is already installed..." message.

Let us know if there is anything else we can help you with.

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”