protected override void OnAsyncQueryCompleted(IAsyncResult result)
 {
     App.Current.Dispatcher.Invoke((Action) delegate
     {
         var orders = new List <AdventureWorksService.SalesOrderHeader>();
         foreach (var item in _query.EndExecute(result))
         {
             orders.Add((AdventureWorksService.SalesOrderHeader)item);
         }
         ProxyServiceQuery.AddData(_query.ToString(), orders);
         OnCompleteSource(orders);
     });
 }
Exemplo n.º 2
0
 public void RefreshData()
 {
     ProxyServiceQuery.ClearData(_query.ToString());
     GetData();
 }
Exemplo n.º 3
0
 private void GetData()
 {
     this.IsLoading = true;
     ProxyServiceQuery.ProcessQuery(this, _query, OnAsyncQueryCompleted);
 }