Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Differentiating between uninstalling/installing and upgrading an application

So, I have this application for which we are producing further development versions.

If the application gets uninstalled by the user (from Add/Remove Programs let's say), then I want the application to delete a certain folder in the file system which contains app-related information.

However, if the application is upgraded (by downloading a newer installer for this app and installing it), then I want it to keep that folder.

I am under the impression (at the moment) that it is not possible to differentiate between uninstalling/installing and just updating an application from one version to another, because the .NET deployment projects treat upgrading as just another uninstall/install procedure, but this should be possible somehow.

Thanks for taking the time and whatever answers I may get.

like image 905
Alex Avatar asked Oct 25 '10 12:10

Alex


People also ask

What is the difference between installing and uninstalling application software?

install means you are adding a program in your system. uninstall means you are removing a program from your system which you previously installed in your system.

What is difference between installation and upgrade?

A clean install differs from an upgrade -- also known as in-place upgrade or in-place install --in which the existing version of the OS or application is retained but updated with the addition of new elements. In an upgrade, user data, files and settings are retained.

What's the difference between uninstall and install?

Both 'instal' and 'install' are correct in the UK. 'Install' is usually used in the US. Choose one and don't swap between the two in the same piece of writing.

What is the difference between uninstalling an app and deleting an app?

Uninstall is removing a program and its associated files from a computer hard drive. The uninstall feature differs from the delete function in that it safely and efficiently removes all associated files, whereas delete only removes part of a program or selected file.


1 Answers

The installer has three GUID codes, ProductCode, PackageCode and UpgradeCode that you can use to manage these scenarios: The UpgradeCode is like an application id and shouldn't change between versions; the PackageCode identifies a release of your setup and the ProductCode identifies a release of your software. You can change the ProductCode by incrementing the ProductVersion value.

Windows uses the ProductCode to see if the application is already installed on a system. If you reinstall using an installer with the same ProductCode and PackageCode you get a Repair/Uninstall option.

like image 57
Rikalous Avatar answered Sep 18 '22 11:09

Rikalous