问题描述
限时送ChatGPT账号..我正在使用 Visual Studio 2015 构建一个新的 Windows 10 UWP(通用 Windows 平台)应用程序.实际上我正在移植我的 Windows 8.1 应用程序,但我是通过创建一个全新的项目并手动拉入每个类来实现的.
I am building a new Windows 10 UWP (Universal Windows Platform) app using Visual Studio 2015. Actually I am porting my Windows 8.1 app, but I did so by creating a whole new project and manually pulling in each class.
我的应用程序构建失败,出现以下错误:
My app is failing to build with the following error:
找不到类型或命名空间名称SettingsPane"(您是否缺少 using 指令或程序集引用?)
The type or namespace name 'SettingsPane' could not be found (are you missing a using directive or an assembly reference?)
有问题的 C# 文件确实有用于 Windows.UI.ApplicationSettings 的 using 语句,即使我尝试将 SettingsPane 完全限定为 Windows,我也会收到错误消息.UI.ApplicationSettings.SettingsPane.
The C# file in question does have a using statement for Windows.UI.ApplicationSettings, and I also get the error even if I try to fully qualify SettingsPane as Windows.UI.ApplicationSettings.SettingsPane.
根据这个,设置窗格应该可用于 Win10 应用程序,在我提到的命名空间中.
According to this, SettingsPane should be available to Win10 apps, in the namespace I mentioned.
所以问题是:为什么我的应用程序无法构建?我是否缺少 dll,或者只是不了解其他内容?
So the question is: why is my app failing to build? Am I missing a dll, or just not understanding something else?
推荐答案
文档顶部的注释说明白了:
The remark at the top of the document clears it up:
[Windows 之后的版本可能会更改设置窗格或不可用10. 不使用 SettingsPane,而是将设置选项集成到应用程序体验中.有关详细信息,请参阅应用设置指南.]
[SettingsPane may be altered or unavailable for releases after Windows 10. Instead of using a SettingsPane, integrate settings options into the app experience. For more info, see Guidelines for app settings.]
而不是使用 SettingsPane,确保您为应用本身的设置构建原生支持.
Instead of using SettingsPane, make sure that you build native support for settings within the app itself.
这篇关于在 Windows 10 版本中找不到 SettingsPane的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
更多推荐
[db:关键词]
发布评论