MSI 自动修复问题解决了吗?
我使用 Visual Studio 2008 创建了一个 MSI 安装程序。我有一些临时文件需要在安装后删除,但自动修复功能让我很困扰。单击安装程序创建的快捷方式将触发自动修复功能。我正在考虑创建自己的快捷方式来避免自动修复。我通过在安装后手动创建快捷方式来尝试此操作。它起作用了。
现在我正在尝试找到一种在安装程序的自定义操作中创建快捷方式的方法。我的问题是对安装程序和安装结果有任何可能的负面影响吗?
谢谢
I created a MSI installer by using Visual Studio 2008. I have some temp files that need to be deleted after the installation, but the auto-repair feature bothers me. The auto-repair feature will be triggered by clicking the shortcut created by the installer. I am thinking about creating my own shortcut to avoid that auto-repair. I tried this by manually creating a shortcut after the installation. It worked.
Now I am trying to find a way to create a shortcut in a custom action of the installer. My question is is there any possible negative effect to the installer and the installation result?
thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
即使您设法故意规避 Windows Installer,如果用户点击“添加/删除程序”中的“修复”按钮,文件仍会返回。相反,您应该寻找在安装过程中使文件临时可用的方法,而无需实际安装它们。遗憾的是,VDPROJ 的局限性如此之大,以至于这并不容易做到。
但是,如果您想忽略所有这些并只是解决问题,请查看针对您的 MSI 运行构建后脚本以使快捷方式不公开。
Even if you managed to intentionally circumvent Windows Installer, the files will still come back if the user hits the Repair button in Add/Remove programs. Instead you should be looking at ways to make the files temporarily available during the install without actually installing them. Sadly VDPROJ is so limited that it doesn't make this very easy to do.
However, if you want to ignore all that and just hack through the problem, take a look at running post build scripts against your MSI to make the shortcut non-Advertised.