WCF RIA Services, SL4
After I edit an entity and save it, how do I reload the datasource to refresh the entities? I have a listbox with entities, and after I edit the entities the datasource is still showing the old information. the MyEntityDataSource.Load() method is not working.
The problem arises because I am not navigating to a separate page to do the editing. I am reusing the flipping window from the SLBA template开发者_Python百科. So when I flip back to the front, i'm basically still using the old object that are still in memory, not creating new objects that will fetch the data again. So I need to renew the old data.
You need to make sure that the ItemsSource property of the ListBox is bound to a collection of objects that implement the INotifyPropertyChanged interface . Ideally the collection itself will implement the INotifyCollectionChanged interface (such as the ObservableCollection generic class).
加载中,请稍侯......
精彩评论