cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
wardbill
Level 4

Component non-key files are not removed on upgrade.

I have a product installed on a machine. It has the following component (and files):

component1
----file1 (keyfile)
----file2
----file3

I have an newer version of the product that has the same component without the non-key files:

component1
----file1 (keyfile)

After upgrade, file2 & file3 are still on the machine. Is it possible to fix this?
NOTE: Action "RemoveExistingProducts" is run after action "InstallFinalize" in this case.

Thanks in advance!
Labels (1)
0 Kudos

(4) Replies
HenryL
Level 5

Is the file1 exactly the same between your old version and new version?
0 Kudos
wardbill
Level 4

Hi,

No, file1 is different. It is an exe file. Both files are versioned. file1 in the new package has a newer version.

Thanks
0 Kudos
Ajay_Ladsaria
Level 7

I suspect that you are running into expected Windows Installer major upgrade behavior when the RemoveExistingProducts action is sequenced after InstallFinalize. In this situation, the updated key file is installed during the InstallFiles action (as it would have been if you were using a minor upgrade), and then at the end of the install MSI is determining that this component does not need to be removed because it is still present in the new version of the product.

Your possible work-around options include the following:
1. Sequence RemoveExistingProducts action in the InstallShield default location of after InstallValidate action (You can also change this same setting in Upgrades View - Upgrade Windows Installer Setup - Major Upgrade Settings.
OR
2. Use the RemoveFile table to remove the files no longer in the component (this approach works in a minor upgrade, so I suspect that it will also work in this case).
OR
3. Use a custom action to delete the files no longer included in the component.

Hope this helps,
Ajay
0 Kudos
wardbill
Level 4

OK Thanks!

I thought that was the case, but figured I'd ask anyway.
0 Kudos