954,500 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

C#, updating installed app with the Windows Installer

Hello, dear All

I have the following problem: i have a .net (C#) app and a Windows Installer project to deploy it. Now i want this Installer project be able not just to install the app onto a 'bare' client machine, but also to check if some previous version of the app has been already installed and update it if necessary.
At first glance, this problem seems as very common and easy to find solution for, but, surprisingly, Google says nothing about it. If somebody knows at least where to look for a solution - i'ld be very grateful for a help.

educated_fool
Newbie Poster
7 posts since Oct 2009
Reputation Points: 10
Solved Threads: 0
 

Click on the installer in your solution explorer and look in the properties window. Set these properties:
DetectNewerInstalledVersion = True
RemovePreviousVersions = True

That will allow you to upgrade machines and stop accidental downgrades.

sknake
Industrious Poster
4,954 posts since Feb 2009
Reputation Points: 1,764
Solved Threads: 735
 

Sknake, thanks a lot! You really helped me to cope with the problem.

educated_fool
Newbie Poster
7 posts since Oct 2009
Reputation Points: 10
Solved Threads: 0
 

You're welcome

Please mark this thread as solved if you have found a solution to your question and good luck!

sknake
Industrious Poster
4,954 posts since Feb 2009
Reputation Points: 1,764
Solved Threads: 735
 

by setting the following properties

DetectNewerInstalledVersion = True
RemovePreviousVersions = True

Setup didn't prompt that another version is already installed, Its updates automatically the previous version installed.

But the problem is it is not updating the exe file; it updates the icon file only.

narin143
Newbie Poster
1 post since Oct 2011
Reputation Points: 10
Solved Threads: 0
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: