OData.Client returns null

2019-06-12 17:12发布

问题:

I am trying to fetch all the data for Customer. However, await mODataClient.For ("Customers").Skip (0).FindEntriesAsync() returns null. I could not able to figure out what I am doing wrong. I am trying to get Northwind Customer data

  using Simple.OData.Client;
  private IEnumerable <IDictionary<string,object>> myCustomers;

  mODataClient = new ODataClient ("http://services.odata.org/Northwind/Northwind.svc/");

  try 
    {
        myCustomers =await mODataClient.For ("Customers").Skip (0).FindEntriesAsync();
    }
 catch 
    {
        await DisplayAlert("Error", "Connection Error", "OK", "Cancel");

    }