toosensitive
toosensitive

Reputation: 2375

windows installer custom action install & uninstall both called when upgrade

Excel AddIn, VS2010, C#, Windows Installer

VS2010, Setup project, RemovePreviousVersion: True, DetectNewerInstalledVersion: True, InstallAllUsers:True

I have some install, uninstall codes in Custom Action

When I do a upgrade install, I notice, install is called first, which installs newer version, and then uninstall is called, which uninstalls the newer version. The end result is not-working AddIn left.

If I do a new install (i.e. no earlier version of AddIn), then only install is called and addin installs successfully

Installer used to work fine when I built it in VS2008, and I just converted projects to VS2010 and then the issue comes up.

Anyone know why ? thanks

Upvotes: 1

Views: 1369

Answers (2)

toosensitive
toosensitive

Reputation: 2375

I already answered in comment under my question. Now answer it explicitly for convenience in search.

I edited my MSI-file in Orca resequenced RemoveExistingProducts right after InstallInitialize (sequence number 1501). This was found in the InstallExecuteSequence table. This was originally sequence number 6550.

Pls refer Web setup project removes files after upgrade from VS2008 to VS2010

Upvotes: 0

saschabeaumont
saschabeaumont

Reputation: 22406

You likely have RemoveExistingProducts scheduled incorrectly - I don't know if this can be changed in VS Setup Packages, but that will be the action that is causing all your pain.

Upvotes: 2

Related Questions