【发布时间】:2014-08-22 02:01:40
【问题描述】:
我正在为演讲创建一个示例:在 Xamarin.Android 中使用 Office 365,但我遇到了一些错误,不知道为什么:/
我知道了:
"System.InvalidOperationException: An error occurred while processing this request. --->
Microsoft.OData.Client.DataServiceTransportException: Error: NameResolutionFailure --->
System.Net.WebException: Error: NameResolutionFailure\n
at System.Net.HttpWebRequest.EndGetResponse (IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n at Microsoft.OData.Client.HttpWebRequestMessage.EndGetResponse (IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n --- End of inner exception stack trace ---\n
at Microsoft.OData.Client.HttpWebRequestMessage.EndGetResponse (IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n at Microsoft.OData.Client.ODataRequestMessageWrapper.EndGetResponse (IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n at Microsoft.OData.Client.DataServiceContext.GetResponseHelper (Microsoft.OData.Client.ODataRequestMessageWrapper request, IAsyncResult asyncResult, Boolean handleWebException) [0x00000]
in <filename unknown>:0 \n --- End of inner exception stack trace ---\n
at Microsoft.OData.Client.BaseAsyncResult.EndExecute[QueryResult] (System.Object source, System.String method, IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n at Microsoft.OData.Client.QueryResult.EndExecuteQuery[Contact] (System.Object source, System.String method, IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n--- End of stack trace from previous location where exception was thrown ---\n
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x00000] in <filename unknown>:0 \n
at System.Runtime.CompilerServices.TaskAwaiter`1[Microsoft.Office365.Exchange.Extensions.IPagedEnumerable`1[Microsoft.Office365.Exchange.IContact]].GetResult () [0x00000]
in <filename unknown>:0 \n at Microsoft.Office365.Exchange.Extensions.DataServiceContextWrapper+<ExecuteAsync>d__2d`2[Microsoft.Office365.Exchange.Contact,Microsoft.Office365.Exchange.IContact].MoveNext () [0x00000]
in <filename unknown>:0 \n--- End of stack trace from previous location where exception was thrown ---\n
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x00000]
in <filename unknown>:0 \n at System.Runtime.CompilerServices.TaskAwaiter`1[Microsoft.Office365.Exchange.Extensions.IPagedEnumerable`1[Microsoft.Office365.Exchange.IContact]].GetResult () [0x00000] in <filename unknown>:0 \n at Office365InXamarinApps.ViewModel.ContactsViewModel+<GetContacts>d__3.MoveNext () [0x000b5] in d:\\DevApps\\GitHub\\Office365InXamarinApps\\scr\\Office365InXamarinApps\\Office365InXamarinApps\\ViewModel\\ContactsViewModel.cs:44 \n--- End of stack trace from previous location where exception was thrown ---\n
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x00000]
in <filename unknown>:0 \n at System.Runtime.CompilerServices.TaskAwaiter`1[System.Collections.Generic.IEnumerable`1[Microsoft.Office365.Exchange.IContact]].GetResult () [0x00000]
in <filename unknown>:0 \n at Office365InXamarinApps.ViewModel.ContactsViewModel+<LoadData>d__0.MoveNext () [0x00030]
in d:\\DevApps\\GitHub\\Office365InXamarinApps\\scr\\Office365InXamarinApps\\Office365InXamarinApps\\ViewModel\\ContactsViewModel.cs:25 " string
还有这个
"Microsoft.OData.Core.ODataErrorException: Object reference not set to an instance of an object.
---> Microsoft.OData.Client.DataServiceQueryException: An error occurred while processing this request.
---> Microsoft.OData.Client.DataServiceClientException: {\"error\":{\"code\":\"ErrorInternalServerError\",\"message\":\"Object reference not set to an instance of an object.\",\"innererror\":{\"message\":\"Object reference not set to an instance of an object.\",\"type\":\"System.NullReferenceException\",\"stacktrace\":\"
at Microsoft.Exchange.Services.OData.Model.ContactSchema.<.cctor>b__2c(Entity e, PropertyDefinition ep, ServiceObject s, PropertyInformation sp)\\r\\n
at Microsoft.Exchange.Services.OData.Model.SimpleEwsPropertyProvider.GetProperty(Entity entity, PropertyDefinition property, ServiceObject ewsObject)\\r\\n
at Microsoft.Exchange.Services.OData.Model.ContactProvider.ItemTypeToEntity(ItemType itemType, IList`1 properties)\\r\\n
at Microsoft.Exchange.Services.OData.Model.ContactProvider.Find(String parentFolderId, ContactQueryAdapter queryAdapter)\\r\\n
at Microsoft.Exchange.Services.OData.Model.FindContactsCommand.InternalExecute()\\r\\n
at Microsoft.Exchange.Services.OData.ODataCommand`2.Execute()\\r\\n
at Microsoft.Exchange.Services.OData.ODataTask.Execute(TimeSpan queueAndDelayTime, TimeSpan totalTime)\"}}}\n
at Microsoft.OData.Client.BaseAsyncResult.EndExecute[QueryResult] (System.Object source, System.String method, IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n at Microsoft.OData.Client.QueryResult.EndExecuteQuery[Contact] (System.Object source, System.String method, IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n --- End of inner exception stack trace ---\n
at Microsoft.OData.Client.QueryResult.EndExecuteQuery[Contact] (System.Object source, System.String method, IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n at Microsoft.OData.Client.DataServiceRequest.EndExecute[Contact] (System.Object source, Microsoft.OData.Client.DataServiceContext context, System.String method, IAsyncResult asyncResult) [0x00000]
in <filename unknown>:0 \n--- End of stack trace from previous location where exception was thrown ---\n
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x00000] in <filename unknown>:0 \n at System.Runtime.CompilerServices.TaskAwaiter`1[Microsoft.Office365.Exchange.Extensions.IPagedEnumerable`1[Microsoft.Office365.Exchange.IContact]].GetResult () [0x00000] in <filename unknown>:0 \n
at Microsoft.Office365.Exchange.Extensions.DataServiceContextWrapper+<ExecuteAsync>d__2d`2[Microsoft.Office365.Exchange.Contact,Microsoft.Office365.Exchange.IContact].MoveNext () [0x00000] in <filename unknown>:0 \n --- End of inner exception stack trace ---\n
at Microsoft.Office365.Exchange.Extensions.DataServiceContextWrapper+<ExecuteAsync>d__2d`2[Microsoft.Office365.Exchange.Contact,Microsoft.Office365.Exchange.IContact].MoveNext () [0x00000]
in <filename unknown>:0 \n--- End of stack trace from previous location where exception was thrown ---\n
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x00000] in <filename unknown>:0 \n at System.Runtime.CompilerServices.TaskAwaiter`1[Microsoft.Office365.Exchange.Extensions.IPagedEnumerable`1[Microsoft.Office365.Exchange.IContact]].GetResult () [0x00000] in <filename unknown>:0 \n
at Office365InXamarinApps.ViewModel.ContactsViewModel+<GetContacts>d__4.MoveNext () [0x000d7] in d:\\DevApps\\GitHub\\Office365InXamarinApps\\scr\\Office365InXamarinApps\\Office365InXamarinApps\\ViewModel\\ContactsViewModel.cs:53 " string
【问题讨论】:
-
您能详细说明一下吗?你想达到什么目的?你有什么尝试解决它?你什么时候得到这些堆栈跟踪的?
-
我在周一、周二和今天 (LOL) 收到错误,就像我说我在做一个演讲的演示 - “在 Xamarin 应用程序中使用 Office 365 API”,这个错误发生在Xamarin.Android 当我尝试从我的帐户中获取联系人时。这是一个BUG!想向团队报告但没有找到方法:/
-
你可以看到这部电影有错误 (dropbox.com/s/eb7vnnbewwdcoxg/debug_untilError.mp4) 我在之前的测试中进行了身份验证,因此它不再询问...
-
发现IOS版本有问题,发到这里:stackoverflow.com/questions/24541318/… :(((((
-
O365 团队的人向我指出了更新的工具:blogs.office.com/2014/08/05/…
标签: android api xamarin office365