Desktop Bridge Window Store 应用程序失败.本地安装工程 [英] Desktop Bridge Window Store Application fails. Local Installation works

查看:20
本文介绍了Desktop Bridge Window Store 应用程序失败.本地安装工程的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个桌面桥应用程序,它从菜单中启动一个 UWP 窗口(选择帮助 > 内容来启动 UWP 窗口).本地安装 (AppPackages\appName_Test\appName_x86_bundle.msixbundle) 工作正常.

我已将 AppPackages\appName_x86_bundle.msixupload 上传到 Microsoft Store,但商店版本无法启动窗口.窗口打开几秒钟,然后关闭.

调试已安装的商店版本时出现以下异常:

在 <MyUwpExeHere>.exe 中的 0x750EB022 (KernelBase.dll) 处抛出异常:WinRT 发起错误 - 0x80131500:'Method 'TreeView.add_ItemInvoked(TypedEventHandler<TreeView, TreeViews> invoked invoked) was但在 MainPage.Connect(int, object) 中被引用.可能缺少一个程序集.'.

树视图控件来自 Microsoft.UI.Xaml.>

此外,当应用程序在本地安装时,会在其中包含一个带有参考信息(包括 Windows.UI.Xaml.Controls.TreeView)的 \WinMetadata\Windows.winmd 文件安装文件夹.商店安装中缺少它.

AppManifest.xml 包含依赖项:

 <TargetDeviceFamily Name="Windows.Desktop" MinVersion="10.0.17763.0" MaxVersionTested="10.0.17763.0"/><PackageDependency Name="Microsoft.VCLibs.140.00" MinVersion="14.0.26706.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/><PackageDependency Name="Microsoft.Advertising.Xaml" MinVersion="10.1805.2.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/><PackageDependency Name="Microsoft.UI.Xaml.2.0" MinVersion="2.1810.18003.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/><PackageDependency Name="Microsoft.NET.Native.Framework.1.7" MinVersion="1.7.25531.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/><PackageDependency Name="Microsoft.NET.Native.Runtime.1.7" MinVersion="1.7.25531.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/></依赖项>

应用程序(一个 32 位和一个 64 位)始终通过商店认证,但商店安装如所述失败 - 在所有机器上.

依赖.appx"文件包含在我认为是预期的.msixupload"中.

感谢您的帮助.

解决方案

解决方案/解决方法是使用 VS 2019 Professional 预览版打包.感谢@StefanWickMSFT 提供指导.

I have a Desktop Bridge application which launches a UWP window from the menu (Select Help > Contents to launch the UWP Window). The local installation (AppPackages\appName_Test\appName_x86_bundle.msixbundle) works fine.

I've uploaded AppPackages\appName_x86_bundle.msixupload to the Microsoft Store but the store version fails to launch the window. The window opens for a couple of seconds and then shuts down.

Debugging the installed store version I get the following exception:

Exception thrown at 0x750EB022 (KernelBase.dll) in <MyUwpExeHere>.exe: WinRT originate error - 0x80131500 : 'Method 'TreeView.add_ItemInvoked(TypedEventHandler<TreeView, TreeViewItemInvokedEventArgs>)' was not included in compilation, but was referenced in MainPage.Connect(int, object). There may have been a missing assembly.'.

The treeview control is from Microsoft.UI.Xaml.

Also when the app is locally installed there is a \WinMetadata\Windows.winmd file with reference information (including Windows.UI.Xaml.Controls.TreeView) in the install folder. It is missing from the Store installation.

The AppManifest.xml includes the dependencies:

  <Dependencies>
    <TargetDeviceFamily Name="Windows.Desktop" MinVersion="10.0.17763.0" MaxVersionTested="10.0.17763.0"/>
    <PackageDependency Name="Microsoft.VCLibs.140.00" MinVersion="14.0.26706.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/>
    <PackageDependency Name="Microsoft.Advertising.Xaml" MinVersion="10.1805.2.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/>
    <PackageDependency Name="Microsoft.UI.Xaml.2.0" MinVersion="2.1810.18003.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/>
    <PackageDependency Name="Microsoft.NET.Native.Framework.1.7" MinVersion="1.7.25531.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/>
    <PackageDependency Name="Microsoft.NET.Native.Runtime.1.7" MinVersion="1.7.25531.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"/>
  </Dependencies>

The applications (one 32-bit and one 64-bit) always pass the store certification but the store installations fail as described - on all machines.

The dependency ".appx" files are not included in ".msixupload" which I think is expected.

Thanks for any help.

解决方案

The solution/workaround was to package using VS 2019 Professional preview edition. Thanks to @StefanWickMSFT for directions.

这篇关于Desktop Bridge Window Store 应用程序失败.本地安装工程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆