I would've expected that setting
RemovePreviousVersion = true
in the setup project would cause the previous version to be removed regardless of if the new version is installed into a different target folder. Is this assumption wrong per se? I did NOT change the UpgradeCode GUID.
However, the old version folder, as well as the entry in "Programs & Features" remains.
In my scenario the current target install folder is
"%ProgramFiles(x86)%\MySoftware v1"
Now I have a major version upgrade to v2 and want to reflect that in the install folder, changing it to
"%ProgramFiles(x86)%\MySoftware v2".
I would prefer if "MySoftware v1" is removed during the upgrade.
Before changing the target folder, it worked as expected. So I assume my setup project settings are correct in general.
What exactly are the criteria that must match between two setup projects, so that it detects that a previous version should be removed? My understanding was, that UpgradeCode is used to uniquely identify a project, but as I pointed out I did not change it.