繁体   English   中英

iOS 11位置无法正常工作

[英]iOS 11 Location not working

我现在添加了与位置相关的所有这4个:

NSLocationWhenInUseUsageDescription NSLocationUsageDescription NSLocationAlwaysUsageDescription NSLocationAlwaysAndWhenInUseUsageDescription

但是我仍然可以在控制台中找到它:该应用程序尝试访问对隐私敏感的数据,而没有使用说明。 应用程序的Info.plist必须同时包含NSLocationAlwaysAndWhenInInUseUsageDescription和NSLocationWhenInInUseUsageDescription键,并向用户说明该应用程序如何使用此数据的字符串值

该应用程序无法获取位置。

打开您的plist作为源代码(右键单击->打开源代码)。 <dict></dict>您必须同时添加键和描述键,如下所示:

    <key>NSLocationWhenInUseUsageDescription</key>
    <string>The app use your location when in use</string>
    <key>NSLocationAlwaysUsageDescription</key>
    <string>The app use your location always</string>

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM