6

我有在Visual Studio 2015年这个错误时尝试了商店的窗户通用应用程序了创建的应用程序包:为商店构建通用应用程序时出现错误:“不包含有效内容的清单引用文件'MyAppName.dll'。”

清单引用文件“MyAppName.dll”这是不是有效载荷的一部分。

错误发生在...\..MyAppSourcePath..\Package.appxmanifest文件中。

这是某种联系Manifest references file 'Bing.Maps.dll' which is not part of the payload但在我的情况下,错误显示出来,只有当构建包店里是关系到MyAppName.dll(其中MyAppName是我的应用程序的名称的名称)。

在MSDN另一个相关的问题:https://social.msdn.microsoft.com/Forums/en-US/f137091e-f550-4eab-b7e2-418149b97d40/error-appx0703-manifest-references-file-myappnamedll-which-is-not-part-of-the-payload?forum=windowsstore

回答

9

<ItemGroup> 
    <AppxSystemBinary Include="MyAppName.dll" /> 
</ItemGroup> 

ItemGroup可以如果错误仍然出现其他组件,例如被扩展针对通用Windows应用程序的Visual Studio工具(v1.1.1)的错误修复于2015年10月5日发布。此更新要求您已经安装了UWP工具v1.1 d。您可以通过在Visual Studio的“帮助”菜单中打开关于Microsoft Visual Studio来确定是否安装了UWP工具1.1。如果您安装了“适用于通用Windows应用程序14.0.23309.00的Visual Studio工具”,则您具有UWP工具1.1。

要安装此更新

  • 您必须在整个安装过程中的互联网连接。

  • 的机器没有Visual Studio的

  • 对于机器安装

  • 对于没有UWP工具的机器1。1安装

    • 对于Visual Studio 2015年的社区,专业版和企业版,您可以通过

      • 修改您的安装程序来安装更新工具安装。

      • 在“通知”窗格中单击UWP工具条目。

      • 使用扩展和更新对话框来更新Visual Studio。

      • 运行安装程序https://dev.windows.com/downloads,这会将更新的工具添加到现有的Visual Studio安装中。

    • 对于Visual Studio 2015年Express Windows版

要确认您已经安装了UWP工具1.1.1更新,

  1. 转到程序和Windows控制面板的功能,然后单击查看已安装的更新。

  2. 寻找“更新为Microsoft Visual Studio 2015年(KB3073097)”,版本14.0.23315

来源:https://social.msdn.microsoft.com/Forums/en-US/73f2d56d-9e8e-4b57-bcfa-0a972dfd75d7/update-11-generating-store-associated-package-fails-for-a-uwp-application-with-a-winrt-component?forum=Win10SDKToolsIssues

+0

我的Visual Studio工具通用的Windows应用程序14.0.25527.01安装我得到这个问题。不知道1.1.1版本号会来自哪里。 – BrainSlugs83

8

原来在Windows 10 SDK,这是已知的问题(更新1.1)。参考:https://social.msdn.microsoft.com/Forums/en-US/73f2d56d-9e8e-4b57-bcfa-0a972dfd75d7/update-11-generating-store-associated-package-fails-for-a-uwp-application-with-a-winrt-component?forum=Win10SDKToolsIssues

要解决此问题,请将以下ItemGroup添加到项目文件中并重新生成软件包。

<ItemGroup> 
    <AppxSystemBinary Include="<Assembly Mentioned in the error>" /> 
</ItemGroup> 

例如,如果该组件名称是MyAppName.dll,包括:

<ItemGroup> 
    <AppxSystemBinary Include="MyAppName.dll" /> 
    <AppxSystemBinary Include="OtherAssembly.dll" /> 
</ItemGroup> 
相关问题