[solved] Prevent install if already installed - Advanced Installer Community
yaeko
Posts: 4
Joined: Fri May 29, 2015 4:52 pm

[solved] Prevent install if already installed

Hello:

I have a project created with Advance Installer - simple project. It is a software installer.

Before, when I tried to install the software was already installed on the system, a message was displayed saying sometinhing like this: "already have an installed version, you must first uninstall it" and the installation wizard will not open.
But now I dont know why this message is not displayed when I try to install the same software already installed. The warning message is not displayed and the installation wizard is runned and appears with these options "disable , repair , uninstall" . But I do not want the user to run the installation wizard if it is already installed. How to prevent run the installation wizard if the software version is already installed? Like before.


Thanks in advance
Last edited by yaeko on Wed Aug 05, 2015 5:51 pm, edited 1 time in total.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Prevent install if already installed

Hello,
Before, when I tried to install the software was already installed on the system, a message was displayed saying sometinhing like this: "already have an installed version, you must first uninstall it" and the installation wizard will not open.
Usually, this message is showed if you created a package, installed it, modified its contents and then you tried to install it again without uninstalling the original one. Basically, Windows Installer can upgrade the original package only if the modified one has a higher version and a different Product Code. If you don't want to create a new version of the package, you need to uninstall the original MSI before installing the modified one.
But now I dont know why this message is not displayed when I try to install the same software already installed. The warning message is not displayed and the installation wizard is runned and appears with these options "disable , repair , uninstall" .
If you run the same installation package for the second time then Windows Installer will run the installer in maintenance mode and the user will then be presented with choices to alter the installed product, repair it or remove it (done through the MaintenanceTypeDlg). This is happening because the installation package has the same PackageCode GUID. A new PackageCode is generated each time you build your project. Think of the PackageCode as some sort of checksum. No two .msi files should ever have the same PackageCode unless they are identical.

Please take a closer look on the Product Identification article.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
yaeko
Posts: 4
Joined: Fri May 29, 2015 4:52 pm

Re: Prevent install if already installed

thanks Dan!
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: [solved] Prevent install if already installed

You're always welcome,

If there is anything else I can help you with, please let me know.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”