WIX 检测待重启

标签 wix

我正在使用带有 WiX 的自定义 BA,我想检测是否有挂起的重启以在我的用户尝试安装之前警告他们,结果却失败了。
How do I reference the Reboot Pending Property in Burn (WiX)
这个问题只告诉我什么不起作用,OP 标记了一个答案,所以没有人回答他的后续问题,“已经被告知 Burn 中的 RebootPending 属性可能与 Windows Installer 使用的属性不完全对应,如何否则我会确保我的应用程序在等待重启时不会尝试安装吗?”
这就是我想知道的。

最佳答案

使用 RebootPending像这样燃烧变量

Bootstrapper.Engine.StringVariables["RebootPending"];

如果是 "1"然后重新启动待定

关于WIX 检测待重启,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18283400/

相关文章:

c++ - 如何在自定义操作 DLL (MSI/Wix) 中获取 "INSTALLED"属性?

wix - 在 Wix 中卸载后运行 devve.exe/setup

Wix - WixBundleOriginalSourceFolder 与 WixBundleSourceProcessFolder

installation - 构建运行另一个安装程序的安装程序

wix - 在 WIX MSI 描述中设置标题

Wix 工具集 : complete cleanup after "disallowing uninstallation of component since another client exists"

蜡刻录 : Custom Bootstrapper upgrade but Installs side by side with older version

wix - 是否可以同时只运行一个 WiX msi 实例?

WiX 和 ARPINSTALLLOCATION

wix - Pyro 和文件排序