Remove file and folders on uninstall

2019-04-11 18:59发布

I am learning WIX to build installer for my app but I am stuck with removing files. My question is how can I remove files and folders on uninstall. When I click on remove button, all the files and folders which the installer created doesn't remove on uninstall.

1条回答
Luminary・发光体
2楼-- · 2019-04-11 19:36

The answer is in the comments above but for future reference there are two things to check first when files are not being removed:

  1. Ensure that you do not have Component/@Guid="". In Specifically setting to an empty string (Guid="") tells the Windows Installer ignore all the stuff built into this Component. Note: WiX v3.6+ you can leave the Guid attribute of the Component element completely and that is fine (a stable GUID will be generated).

  2. Ensure the you do not have Component/@Permanent="yes". Obviously, that tells the Windows Installer to not uninstall the stuff.

查看更多
登录 后发表回答