[英]Access Denied exception when calling Windows Phone 8.1 ContactManager.RequestStoreAsync();
Using following tutorial from MSDN i am trying to retrieve contacts. 使用来自MSDN的以下教程,我试图检索联系人。 But getting Access denied exception.
但是获取Access拒绝异常。 Quickstart: Selecting user contacts Windows Phone Store app
快速入门:选择用户联系人Windows Phone Store应用
PS: I am using windows phone 8.1 universal app. PS:我正在使用Windows Phone 8.1通用应用程序。
I am getting exception at following line 我在以下行遇到异常
ContactStore contactStore = await ContactManager.RequestStoreAsync();
and below is the exception stack trace 下面是异常堆栈跟踪
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult() at App3.Members.d__0.MoveNext() 在System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task任务)在System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()在App3.Members.d__0.MoveNext()
Check the Requirements section in the documentation of ContactStore class documentation of ContactStore class . 检查ContactStore类的ContactStore类文档中的“需求”部分。
Edit WMAppManifest.xaml and add ID_CAP_CONTACTS
capability. 编辑WMAppManifest.xaml并添加
ID_CAP_CONTACTS
功能。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.