【问题标题】:WiX: Error RegistryKey element contains an unexpected attribute 'ForceDeleteOnUninstall'WiX:错误 RegistryKey 元素包含意外属性“ForceDeleteOnUninstall”
【发布时间】:2013-03-13 18:14:35
【问题描述】:

我是 WiX 的新手。我刚刚安装了WixW 3.7,以便构建一个开源JiraSVN plugin。但是在 Visual Studio 中构建中断并出现以下错误:

The RegistryKey element contains an unexpected attribute 'ForceDeleteOnUninstall'.
The RegistryKey element contains an unexpected attribute 'ForceCreateOnInstall'.

这些错误引用了 product.wxs 文件,该文件包含以下元素:

<Component Id="C__Registry" Guid="{40D60013-...D30D5}" Win64="yes">
<RegistryKey Root="HKCR" Key="CLSID\{CF732FD7-...1A7E9D}" ForceDeleteOnUninstall="yes">
    <RegistryValue Value="TortoiseSVN Jira Plugin" Type="string" Action="write" />
    <RegistryKey Key="Implemented Categories">
        <RegistryKey Key="{3494FA92-...5E7831}" ForceCreateOnInstall="yes" />           </RegistryKey>
</RegistryKey>
</Component>

我还收到以下警告:

The 'ForceDeleteOnUninstall' attribute is not declared. 
The 'ForceCreateOnInstall' attribute is not declared.   

根据我在 WiX 文档中可以找到的内容,这些是 WiX 框架中的标准属性。那么是什么原因导致他们无法识别呢? 应该在哪里声明它们?

【问题讨论】:

    标签: wix wix3.7


    【解决方案1】:

    首先,为什么要添加这些属性?从您发送的 sn-p 中,它们是不必要的,只会使您的安装膨胀。不需要强迫任何东西。

    其次,您的 Visual Studio 计算机上必须安装 WiX v3.5 或更低版本。这些属性是在 WiX v3.6 中添加的。

    【讨论】:

    • 我无法解释为什么会有这些属性,因为我没有添加它们,也不知道它们的用途。
    • ...但是您发现了失败。不知何故,我点击了 Wix 以前版本的下载页面的链接,而不是最新版本(并且没有注意到差异)。谢谢!
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-06-26
    • 1970-01-01
    相关资源
    最近更新 更多