Refresh a DataGrid Cache
-
Friday, May 04, 2012 8:01 PM
Hi
I have a datagrid that is not refreshing. once loaded. The server side data has not change, but changing the below filter on the client side. How do I modify the below code to clear the cache
EntityQuery<ReNtZTouch.Web.Main> query = from c in _MainViewContext.GetMainsQuery() where c.CustID == xCust select c; LoadOperation<ReNtZTouch.Web.Main> loadOp = this._MainViewContext.Load(query); mainDataGrid.ItemsSource = loadOp.Entities;
All Replies
-
Tuesday, May 08, 2012 12:09 PM
Hi asid,
To clear the DomainContext's cached instance, please pass LoadBehavior to Load method like below
LoadOperation<Customer> loadOp = this._customerContext.Load(query, LoadBehavior.RefreshCurrent , false);
For details, please refer to
Best Regards,

