WiX引导-元素包含一个未处理的扩展属性



我在使用WiX Toolset 4.0开发WiX引导应用程序时遇到问题。

我现在的主要目标是检查并防止在运行安装程序时重新安装.NET 4.5 Framework。因此,我需要使用xmlns:util="http://schemas.microsoft.com/wix/UtilExtension"命名空间,但我得到以下错误。

Fragment元素包含未处理的扩展属性"RegistrySearch"。请确保中属性的扩展http://schemas.microsoft.com/wix/UtilExtension'命名空间具有已提供。

我已经添加了对WixUtilExtension.dll的引用,并且在尝试从BalExtension命名空间添加PrereqPackage时也出现了此错误。

ExePackage元素包含未处理的扩展属性"PrereqPackage"。请确保中属性的扩展http://schemas.microsoft.com/wix/BalExtension'命名空间具有已提供。

这是我的Bundle.wxs文件。

<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"
     xmlns:util="http://schemas.microsoft.com/wix/UtilExtension"
     xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
  <Bundle Name="Camille" 
          Version="1.0.0.0" 
          Manufacturer="Dummy" 
          UpgradeCode="A48D5F63-0E35-4521-A659-36726E31D080" 
          Compressed="yes"
          DisableModify="button"
          >
    <!--TODO: Add IconSourceFile argument-->
     <BootstrapperApplicationRef Id="ManagedBootstrapperApplicationHost">       
      <Payload SourceFile="..DummyInstaller.BootstrapperApplicationBootstrapperCore.config"/>
      <Payload SourceFile="..DummyInstaller.BootstrapperApplicationbinReleaseDummyInstaller.BootstrapperApplication.dll"/>
      <Payload SourceFile="..LibsDummy.UI.Tools.WPF.MVVMFramework.dll"/>
      <Payload SourceFile="..LibsMicrosoft.Deployment.WindowsInstaller.dll"/>     
     </BootstrapperApplicationRef>
 
		<Chain>
      <PackageGroupRef Id='Netfx45'/>
      <MsiPackage SourceFile="..MSIDummyInstaller.msi" Id="DummyPackageId" Cache="yes" Visible="no" Vital="yes"/>
		</Chain>    
	</Bundle>
  
  <Fragment>
    <util:RegistrySearch Root="HKLM" Key="SOFTWAREMicrosoftNet Framework SetupNDPv4Full" Value="Version" Variable="Netfx4FullVersion" />
    <util:RegistrySearch Root="HKLM" Key="SOFTWAREMicrosoftNet Framework SetupNDPv4Full" Value="Version" Variable="Netfx4x64FullVersion" Win64="yes" />
        
    <!-- .NET 4.5 only installed if Vista or higher AND it's not already installed-->
    <PackageGroup Id="Netfx45">
      <ExePackage Id="Netfx45" Cache="no" Compressed="no" PerMachine="yes" Permanent="yes" Vital="yes" InstallCommand="/q"
                  bal:PrereqPackage="yes"
                  SourceFile="dotnetfx45_full_x86_x64.exe"
                  DownloadUrl="http://download.microsoft.com/download/b/a/4/ba4a7e71-2906-4b2d-a0e1-80cf16844f5f/dotnetfx45_full_x86_x64.exe"
                  DetectCondition="(Netfx4FullVersion=&quot;4.5.50709&quot;) AND (NOT VersionNT64 OR (Netfx4x64FullVersion=&quot;4.5.50709&quot;))"
                  InstallCondition="(VersionNT >= v6.0 OR VersionNT64 >= v6.0) AND (NOT (Netfx4FullVersion=&quot;4.5.50709&quot; OR Netfx4x64FullVersion=&quot;4.5.50709&quot;))"/>
    </PackageGroup>  
  </Fragment>
</Wix>

我认为你有错误的iis链接。请检查此迁移页面。

修复:将http://schemas.microsoft.com/wix/BalExtension重命名为http://wixtoolset.org/schemas/v4/wxs/bal

修复:将http://schemas.microsoft.com/wix/UtilExtension重命名为http://wixtoolset.org/schemas/v4/wxs/util

最新更新