janderssen
Posts: 18
Joined: Tue Nov 20, 2007 7:19 am

How to know when an uninstall is from a build incremented

Hi,

What I would like to acheive is as follows :

As the build machine builds our product, we increment it from ie 3.0.0.1 to 3.0.0.2 However, this is not really an upgrade as such, it is just a testing version, and we would like to just simply overwrite the existing files (except for ones flagged as to not overwrite) on the machine with the new built files, but currently it does a full Un-Install and then a install. How do I stop this from happening.

So to make it a bit clearer, we install for example 5 executables and 2 datafiles, when the next build is done, we just simply want to overwrite he executables only, but leave everything as is. So maybe a better question is, what is the recommended way of doing this?

In regards to the (silent) un-install, how can I tell if the un-install is from an upgraded installer calling it before installing the new version, or if the user is un-installing the product by click in add remove programs, or on a shortcut to the uninstall in the start menu ? The reason for this is so I can make a valid assumption if the user is uninstalling the product permanently, so I can remove the database etc.. but if the user is upgrading to a new version, I dont want to delete the database. So I suppose, to sum up the question - "when is an uninstall a uninstall, not an upgrade uninstalling the old product then installing a new product."

Cheers
Jason
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: How to know when an uninstall is from a build incremented

Hi Jason,
So to make it a bit clearer, we install for example 5 executables and 2 datafiles, when the next build is done, we just simply want to overwrite he executables only, but leave everything as is. So maybe a better question is, what is the recommended way of doing this?
This can be done only by using a patch. In order to create a patch you can follow our Patch Authoring tutorial. Also, it is recommended that you read more about patch projects.
In regards to the (silent) un-install, how can I tell if the un-install is from an upgraded installer calling it before installing the new version, or if the user is un-installing the product by click in add remove programs, or on a shortcut to the uninstall in the start menu ?
If the uninstall is performed by an upgrade, the UPGRADINGPRODUCTCODE property has a value. However, if the uninstall is launched from "Add or Remove Programs" or by a shortcut to uninstall or by using a command line, the UPGRADINGPRODUCTCODE property is empty.

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

Return to “Common Problems”