User interface 创建自定义对话框时出现WiX编译错误
我一直试图在User interface 创建自定义对话框时出现WiX编译错误,user-interface,wix,windows-installer,wix3.5,User Interface,Wix,Windows Installer,Wix3.5,我一直试图在WixUI\u InstallDirUI序列中插入一个自定义对话框。我有一个名为Product.wxs的“主”文件和另一个名为InstallTypeDlg.wxs的文件中的自定义对话框,这两个文件都存在于Installer.wixproj中 在InstallTypeDlg.wxs中,我有以下内容: <?xml version="1.0" encoding="UTF-8"?> <Wix xmlns="http://schemas.microsoft.com/wix
WixUI\u InstallDir
UI序列中插入一个自定义对话框。我有一个名为Product.wxs
的“主”文件和另一个名为InstallTypeDlg.wxs
的文件中的自定义对话框,这两个文件都存在于Installer.wixproj
中
在InstallTypeDlg.wxs
中,我有以下内容:
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Fragment>
<UI>
<Dialog Id="InstallTypeDlg" Width="370" Height="270" Title="Select Install Type">
<Control Id="InstallTypeSelection" Type="RadioButtonGroup" X="20" Y="55" Width="330" Height="120" Property="InstallType">
<RadioButtonGroup Property="InstallType">
<RadioButton Text="Type 01" Value="1" X="5" Y="0" Width="250" Height="15" />
<RadioButton Text="Type 02" Value="2" X="5" Y="20" Width="250" Height="15" />
</RadioButtonGroup>
</Control>
<Control Id="Back" Type="PushButton" X="180" Y="243" Width="56" Height="17" Text="!(loc.WixUIBack)" />
<Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Default="yes" Text="!(loc.WixUINext)" />
<Control Id="Cancel" Type="PushButton" X="304" Y="243" Width="56" Height="17" Cancel="yes" Text="!(loc.WixUICancel)">
<Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>
</Control>
<Control Id="BannerBitmap" Type="Bitmap" X="0" Y="0" Width="370" Height="44" TabSkip="no" Text="!(loc.SetupTypeDlgBannerBitmap)" />
<Control Id="BannerLine" Type="Line" X="0" Y="44" Width="370" Height="0" />
<Control Id="BottomLine" Type="Line" X="0" Y="234" Width="370" Height="0" />
<Control Id="Title" Type="Text" X="15" Y="6" Width="200" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.SetupTypeDlgTitle)" />
<Control Id="Description" Type="Text" X="25" Y="23" Width="280" Height="15" Transparent="yes" NoPrefix="yes" Text="!(loc.SetupTypeDlgDescription)" />
<Control Id="TypicalText" Type="Text" X="60" Y="85" Width="280" Height="20" Text="!(loc.SetupTypeDlgTypicalText)" />
</Dialog>
</UI>
</Fragment>
</Wix>
现在,当我编译这个项目时,我得到了以下错误:
InstallTypeDlg.wxs(8,0):错误LGHT0094:对“Fragment:”部分中的符号“Property:InstallType”的引用未解析。
我不知道为什么。我忘了什么吗-/
我是WiX的新手,昨天才学会。任何帮助都将不胜感激
我正在使用。可能,您只需要在使用该属性之前定义它,即:
<Property Id="InstallType" Value="some default value" />
有效,谢谢!我读过的教程没有提到这一点,我假设该属性是由tagGreat自动创建的。通常,如果出现这样的错误,这意味着您必须定义被引用的实体。谢谢。我已经定义了属性,但没有为其指定默认值。这一切都不同了,谢谢。和大脚怪一样。需要预先设置属性的值。
<Property Id="InstallType" Value="some default value" />