Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在学习 WIX 为我的应用程序构建安装程序,但我一直在删除文件。我的问题是如何在卸载时删除文件和文件夹。当我单击删除按钮时,安装程序创建的所有文件和文件夹在卸载时都不会删除。
答案在上面的评论中,但为了将来参考,当文件未被删除时,首先要检查两件事:
确保您没有 Component/@Guid=""。在特别设置为空字符串 (Guid="") 告诉 Windows 安装程序忽略此组件中内置的所有内容。注意:WiX v3.6+ 您可以完全保留 Component 元素的 Guid 属性,这很好(将生成稳定的 GUID)。
确保您没有 Component/@Permanent="yes"。显然,这告诉 Windows 安装程序不要卸载这些东西。