移动 Wix <UI>到另一个文件 [英] Moving Wix <UI> to another file

查看:19
本文介绍了移动 Wix <UI>到另一个文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将我的 wix 文件拆分为两个单独的文件.使用我的 下存在的所有内容</UI> 标记位于此辅助文件中.

I am trying to split out my wix file into two separate files. With everything that exists under my <UI> </UI> tag living in this secondary file.

我在谷歌上搜索了很多,但我似乎没有得到任何结论性的结果.

I have googled this quite a bit but I don't seem to be getting any conclusive results.

有人成功过吗?

推荐答案

在您的 Wix 项目中添加对 WixUIExtension 的引用

In your Wix project add the reference to the WixUIExtension

在您的 Product.wxs(主安装文件)中添加这样一行

In your Product.wxs (Main Install file) add a line like this

<UIRef Id="UserInterface"/>

将 UserInterface.wxs 添加到您的项目解决方案并自定义您的 MSI 的 UI:

Add the UserInterface.wxs to your project solution and customize the UI of your MSI:

  <TextStyle Id="WixUI_Font_Normal" FaceName="Tahoma" Size="8" />
  <TextStyle Id="WixUI_Font_Bigger" FaceName="Tahoma" Size="9" Bold="yes" />
  <TextStyle Id="WixUI_Font_Title"  FaceName="Tahoma" Size="9" Bold="yes" />

  <Property Id="DefaultUIFont" Value="WixUI_Font_Normal" />

  <DialogRef Id="ProgressDlg" />
  <DialogRef Id="ErrorDlg" />
  <DialogRef Id="FilesInUse" />
  <DialogRef Id="FatalError" />
  <DialogRef Id="UserExit" />
  <DialogRef Id="InstallDirDlg"/>
  <DialogRef Id="FeaturesDlg" />




  <Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="FeaturesDlg" Order="2"></Publish>

  <Publish Dialog="FeaturesDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg">1</Publish>

  <Publish Dialog="InstallDirDlg" Control="Back" Event="NewDialog" Value="FeaturesDlg">1</Publish>
  <Publish Dialog="InstallDirDlg" Control="ChangeFolder" Property="_BrowseProperty" Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
  <Publish Dialog="InstallDirDlg" Control="ChangeFolder" Event="SpawnDialog" Value="BrowseDlg" Order="2">1</Publish>
  <Publish Dialog="InstallDirDlg" Control="Next" Event="SetTargetPath" Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
  <Publish Dialog="InstallDirDlg" Control="Next" Event="NewDialog" Value="ExitDialog" Order="2">1</Publish>



  <Publish Dialog="ExitDialog" Control="Finish" Event="EndDialog" Value="Return" Order="999">1</Publish>

</UI>
<UIRef Id="WixUI_Common" />

此代码的完整示例可以在此 答案

The complete sample of this code can be found at this answer

看看这个链接,解释如何创建自定义对话框

Look at this link, explains how to create Custom Dialogs

祝你好运!

这篇关于移动 Wix &lt;UI&gt;到另一个文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆