我需要一些帮助来创建没有许可证 UI 的 WiX Bootstrapper。我有一个 WiX MSI 设置,其中包含以下所有屏幕:欢迎、许可证、目标文件夹和进度 UI。
此 MSI 应使用 WiX Bundle 通过 Bootstrap.exe 运行。当我运行它时,我可以看到两个许可证屏幕 - 一个是 Bootstrapper,另一个是我的 MSI 屏幕。那么我怎样才能消除/隐藏 Bootstrap 许可证 UI。
有没有一种方法可以直接运行安装,而无需单击 Bootstrapper UI 中的安装按钮?
最佳答案
UPDATE: Simpler approach then Custom Bootstrapper Application (described below).
Blank Hyperlink URL: It seems there is a simple workaround whilst still using the Standard Bootstrapper Application. You can specify a blank URL for the license:
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
<Bundle Name="MyTestApp" Version="1.0.0.0"
Manufacturer="Someone" UpgradeCode="PUT-GUID-HERE">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.HyperlinkLicense">
<bal:WixStandardBootstrapperApplication LicenseUrl="" /> <!--Blank URL-->
</BootstrapperApplicationRef>
<Chain>
<MsiPackage SourceFile="Installer.msi" DisplayInternalUI="yes" />
</Chain>
</Bundle>
</Wix>
<小时/>Direct Install: I do not know of a way to invoke the install directly without clicking the install button, short of running the whole bundle silently without a GUI at all.
先决条件?:您是否需要 Bootstrap 来安装先决条件,或者您只想将 MSI 包装在 setup.exe
?您还可以使用其他一些工具(Zip 工具、VS 安装程序项目等)创建 setup.exe 文件。
基本原理:我不知道当您使用标准 Bootstrap 应用程序时隐藏 Bootstrap 许可证对话框的方法。我相信这个想法是所有 MSI 都应该在 Bootstrap 启动的静默模式下运行,因此每个设置的许可证对话框都是隐藏的。
自定义 Bootstrap 应用程序:我还没有真正尝试过这一点,但您可以创建自己的 Bootstrap 应用程序 - 运行 setup.exe GUI 的应用程序 - 然后您可以隐藏许可证对话框。我现在能想到的唯一样本是 Rainer Stropek's sample here 。没什么可继续的,但我目前得到的最好的。这是一个简单的示例,具有非常基本的 GUI。
关于没有许可证 UI 的 Wix Bootstrapper,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54093632/