UWP应用中ResourceDictionary的资源仅在Xbox上可以识别

问题描述 投票:1回答:1

我正在处理的项目中发生了一个特殊的问题。当在PC上本地运行应用程序时,无法识别添加到UWP app资源词典的某些资源,但是在Xbox上运行时,则可以识别这些资源。

从Visual Studio在PC上运行应用程序(Debug | x64)时,启动时会弹出以下异常:

Windows.UI.Xaml.Markup.XamlParseException
  HResult=0x802B000A
  Message=The text associated with this error code could not be found.

Cannot find a Resource with the Name/Key SimpleTextBox [Line: 45 Position: 41]
  Source=<Cannot evaluate the exception source>
  StackTrace:
<Cannot evaluate the exception stack trace>

此异常在InitializeComponent method of LoginView.xaml.cs上触发。

样式定义为here,并且包含ResourceDictionary here

uwp uwp-xaml xbox-one
1个回答
0
投票

我下载了原始样本存储库,并确实在xbox上成功运行,但在PC上失败,并提示

© www.soinside.com 2019 - 2024. All rights reserved.