Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio Set-Up Doesn't uninstall previous version of the build

I need to constantly release a new executable with modifications to send to the end user. The Set-UP Projects Properties are set to

RemovePreviousVersion = True
DetectNewerInstalledVersion = True

When I release a new build, I increment the Version AND change the Product Code.

(Since I am using Visual Studio 2010 - when you increment the Version it automatically changes the product code, but I've tried to change it manually also).

When the build is done - the previous version doesn't uninstall.

The settings are below:

Set-up Project Properties in visual studio 2010 ultimate

EDIT: After some more research I've found that fileVersion of the project also needs to be increased. I've done so in the AssemblyInfo.cs

[assembly: AssemblyVersion("0.0.0.2")]
[assembly: AssemblyFileVersion("0.0.0.2")]

Both versions were 0.0.0.1 . After rebuilding - same issue.

Any ideas on how to get this work?

like image 490
Sam Avatar asked Dec 27 '11 01:12

Sam


1 Answers

I have run into this also. What I found is the change has to be something greater than a change of the Revision Number. At the Minimum it needs to be the Build.

Major Version.Minor Version.Build Number.Revision

So in Your Case:

[assembly: AssemblyVersion("0.0.2.0")]
[assembly: AssemblyFileVersion("0.0.2.0")]
like image 75
Mark Hall Avatar answered Sep 20 '22 21:09

Mark Hall