![](/img/trans.png)
[英]MobileServiceInvalidOperationException Xamarin.Forms connecting to Azure using LINQ
[英]MobileServiceInvalidOperationException is thrown on Xamarin.WindowsPhone 8.1 project
我正在嘗試使用Azure移動服務和Xamarin。 我遵循官方教程的所有說明,為應用程序創建了Azure后端,並從Azure下載了Xamarin.Forms的示例快速入門應用程序。 TodoItemManager.cs
有代碼:
public async Task<ObservableCollection<TodoItem>> GetTodoItemsAsync(bool syncItems = false)
{
try
{
IEnumerable<TodoItem> items = await todoTable
.Where(todoItem => !todoItem.Done)
.ToEnumerableAsync();
return new ObservableCollection<TodoItem>(items);
}
catch (MobileServiceInvalidOperationException msioe)
{
Debug.WriteLine(@"Invalid sync operation: {0}", msioe.Message);
}
catch (Exception e)
{
Debug.WriteLine(@"Sync error: {0}", e.Message);
}
return null;
}
並且我收到了MobileServiceInvalidOperationException
消息,消息為“ Invalid sync operation: The request could not be completed. (Not Found)
”。
我已經在UWP App上測試了Azure后端,並且工作正常。 因此看起來WP8.1項目中有問題。 有人可以幫忙這個例外嗎?
所以..我忘了在Windows Phone上啟用Internet連接
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.