0

在旧版本的 WiX 中,我看到了以下 xml 片段,用于检查是否存在并在操作系统上不存在时.NET Framework 4.0中止安装。.NET Framework但是在这篇关于How To: Check for .NET Framework Versions的官方文档中没有提到任何RegistrySearch元素。问题: RegistrySearch 元素是否仍需要包含在此处,或者在最新版本3.11中不需要WiX

<Property Id="VSTORUNTIMEREDIST">
  <RegistrySearch
    Id="VSTORuntimeRedist"
    Root="HKLM"
    Key="SOFTWARE\Microsoft\VSTO Runtime Setup\v4R"
    Name="Version"
    Type="raw" />
</Property>
<Condition
  Message="The Visual Studio 2010 Tools for Office Runtime is not installed. Please download and install from http://www.microsoft.com/en-us/download/details.aspx?id=20479.">
  <![CDATA[Installed OR VSTORUNTIMEREDIST>="10.0.30319"]]>
</Condition>

<PropertyRef Id="NETFRAMEWORK40FULL"/>
<Condition Message="This application requires .NET Framework 4.0.">
  <![CDATA[Installed OR NETFRAMEWORK40FULL]]>
</Condition>
4

1 回答 1

0

在您的代码中,RegistrySearch 与 Office 运行时的 Visual Studio 2010 工具相关,而不与 .NET Framework 相关。测试 .NET 的存在不需要它。

于 2017-04-24T21:27:08.260 回答