【问题标题】:Reference WixUI Error参考 WixUI 错误
【发布时间】:2013-08-15 20:36:24
【问题描述】:

环境:Win7+VS2012+Wix3.7。

编译错误:

未解决部分中对符号“WixUI:WixUI_InstallDir”的引用 '产品:{9E327731-0EAC-4A02-9C3C-9C136ACCE05B}'

代码如下:

<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
  <Product Id="{9E327731-0EAC-4A02-9C3C-9C136ACCE05B}" Name="SetupProject2" Language="1033" Version="1.1.1.1" Manufacturer="Anser" UpgradeCode="61eb40a6-21d9-4f23-9c9e-078b98707371">
    <Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />

    <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." />
    <MediaTemplate />
    <Feature Id="ProductFeature" Title="SetupProject2" Level="1">
      <ComponentGroupRef Id="ProductComponents" />
    </Feature>
    <Property Id="WIXUI_INSTALLDIR">INSTALLDIR</Property>
    <UIRef Id="WixUI_InstallDir"/>
  </Product>

  <Fragment>
    <Directory Id="TARGETDIR" Name="SourceDir">
      <Directory Id="ProgramFilesFolder">
        <Directory Id="INSTALLFOLDER" Name="SetupProject2" />
      </Directory>
    </Directory>
  </Fragment>

  <Fragment>
    <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
      <!-- TODO: Remove the comments around this Component element and the ComponentRef below in order to add resources to this installer. -->
      <!-- <Component Id="ProductComponent"> -->
      <!-- TODO: Insert files, registry keys, and other resources here. -->
      <!-- </Component> -->
      <Component Id="ProductComponent" DiskId="1" Guid="{65F464D6-BC0B-4679-9546-CF8B6CFCE184}">     
        <File Name='test.exe' Source="test.exe" />
      </Component>
    </ComponentGroup>
  </Fragment>
</Wix>

找不到原因,谁能帮帮我?

【问题讨论】:

  • 它有点重复,但实际上这个特定问题中写的特定错误消息是什么把我带到这里,最终导致我找到有答案的副本,所以我认为这个问题应该保留我会投票的

标签: wix wix3.7


【解决方案1】:

在项目中引用WixUIExtension.dll

我参考了以下站点中的类似问题。 How to add a UI to a WiX 3 installer?

【讨论】:

  • 假设您已经安装了工具集,它位于:%PROGRAMFILES(X86)%\WiX Toolset v3.11\bin\
猜你喜欢
  • 2013-02-11
  • 2015-07-30
  • 2018-03-12
  • 2012-12-27
  • 2023-03-30
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多