Hello,
I'm trying to create a simple real-time application with the grid control.
Currently our data source is an observable collection of objects that implement INotifyPropertyChanged. It consists of a grid of 1000 rows and 20 columns, where every single value in the data source is updated every 500ms. This means that there are 40,000 updates every second to the data source.
xamDataGrid will lazy subscribe to each row as it appears on screen, however it never unsubscribes, meaning that once you have viewed every row, the grid makes 40,000 calls a second to the dataset to get the data rather than the 400 or so of the cells actually on screen.
Is it possible to somehow setup the grid so that it only actively subscribes to the data that is onscreen at that time? Any suggestions appreciated.
ThanksSteve Mortimer
Hi Joe,
This approach worked fine if i have a ObservableCollection<MyObject>, but now I am willing to use ColectionView as my source for the gridn and have the SourceCollection be ObservableCollection<MyObject>. So i have my class implementing CollectionView and ITypedList to expose my properties for binding and unfortunately is not working, by debugging it looks like it is ignoring the ITypeList interface as the GetProperties method never gets fired. Am I doing something wrong?
Regards,
Stefan
Steve,
As far as the schedule for the next public hotfix, I don't know when that will be. The best way to keep up with the latest hotfixes is thru this blog http://blogs.infragistics.com/tags/Hot+Fix/default.aspx.
As far as filtering and fixed rows is concerned, we don't comment publicly about future features. I can tell you that it is not in the 7.2 version about to be released. I do know that these are features that have been requested by other customers though.
Sorry I can't be more explicit.
Thanks, that is fantastic news. Do you know when the hot fix will be available?
Do you have any news on AutoFilters or fixed rows?
Thanks for your help
Steve
I'm not sure why each property is read 3 times. However, for normal fields we don't do any caching of cell values, this is by design. Whenever we need the value we request it from the data item. Unbound cell values are cached and if BindingPath is specified we hook up a standard binding to maintian synchronization.
If the data item implements INotifyPropertyChanged then the DataRecord wires up the INotifyPropertyChange event. If there is no CellValuePresenter in view for the cell being changed then we don't ask for the cell's value from the data item. However there is some minor overhead in just determining that fact. We should unwire the event when the DataRecord is scrolled out of view to eliminate this, I will enter a bug into our system to make sure it gets done.
BTW, the original problem has been fixed, when using UnboundFields we now clear those bindings when the CellValuePresenters are no longer associated with the cell, i.e. they are scrolled out of view. Unfortunately, this fix was made too late to get into the 7.2 release and will have to wait for the next hot fix.
Thanks for your help so far. While this does work i have a noticed that each property is read by the grid 3 times. Any ideas why thats the case?
Also is there any way you can unsubscribe from the INotifyPropertyChanged event when your not activly requiring it?
Our application is still fireing 40,000 events a second even though only 600 or so are actually read (3 times each per event)
Thanks