Xml Wix安装程序PropertyRef架构验证错误
将Xml Wix安装程序PropertyRef架构验证错误,xml,wix,Xml,Wix,将PropertyRef元素添加到我的包元素会在编译过程中产生错误 这是我的*.wxs文件 <?xml version="1.0" encoding="UTF-8"?> <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension"> <Product Id="*" Name="MyProduc
PropertyRef
元素添加到我的包
元素会在编译过程中产生错误
这是我的*.wxs文件
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension">
<Product Id="*" Name="MyProduct" Language="1033" Version="!(bind.FileVersion.MyApplication.exe)" Manufacturer="MyManufacturer" UpgradeCode="SOME-GUID">
<PropertyRef Id="WIX_IS_NETFRAMEWORK_461_OR_LATER_INSTALLED" />
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
...
</Product>
...
</Wix>
查看PropertyRef的显示,
Product
应该是PropertyRef
的有效父级。此错误可以通过将PropertyRef
元素放在Package
元素之后来修复
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension">
<Product Id="*" Name="MyProduct" Language="1033" Version="!(bind.FileVersion.MyApplication.exe)" Manufacturer="MyManufacturer" UpgradeCode="SOME-GUID">
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
<PropertyRef Id="WIX_IS_NETFRAMEWORK_461_OR_LATER_INSTALLED" />
...
</Product>
...
</Wix>
...
...
将PropertyRef
元素放在Package
元素之后,可以修复此错误
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension">
<Product Id="*" Name="MyProduct" Language="1033" Version="!(bind.FileVersion.MyApplication.exe)" Manufacturer="MyManufacturer" UpgradeCode="SOME-GUID">
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
<PropertyRef Id="WIX_IS_NETFRAMEWORK_461_OR_LATER_INSTALLED" />
...
</Product>
...
</Wix>
...
...