5 Answers, 1 is accepted
Do you refresh by calling Rebind() on the GridView every ninety seconds? A far better approach would be to have your objects implement INotifyPropertyChanged and store them in an ObservableCollection. That way when you change your data, the GridView refreshes only the parts it needs to automatically, with none of the performance hit incurred by calling Rebind() from a timer so frequently.
Kind regards,Yavor Georgiev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
I am already using the MVVM pattern any my view models implement INotifyPropertyChanged. I never call rebind on the grid. All databinding is done via xaml binding syntax and observable collections. When my timer expires, I just refresh my ObservableCollection.
Has there been any other reports of this mis-rendering of the RadGridView? Any ideas what would be causing it?
Thanks & regards,
Ciaran O'Neill
This is a very peculiar scenario. Let me get this straight: you refresh your ObservableCollection so that items added, removed or changed will show up in the GridView, right? The thing is, if you're already using ObservableCollections and INotifyPropertyChanged, the GridView should pick up any changes in your models and refresh itself automatically.
Could you please try to comment out the timer functionality and let me know if the GridView updates itself when the model changes?
Yavor Georgiev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
I need the timer because I'm working in SIlverlight in a disconnected scenario and every 90 seconds I poll the database via a service and update the ObservableCollection which is the ItemsSource of the RadGrid.
The issue I'm having is not that the RadGrid is not refreshing. The RadGrid is refreshing, but when I'm on another tab and the refresh happens the rendering of the grid is affected. Please refer to my screenshots attached to my inital post to see what I am referring to
Thanks,
Ciaran O'Neill
I have tried to reproduce the problem in a sample project as best as I could, but so far I have been unable to do so. Please see if you can modify it yourself so as to introduce the faulty behavior. I'm afraid that it won't be possible to debug the problem otherwise.
On a side note, have you applied any custom styling to your GridView? You can also try it with our stock default theme, Office_Black. Perhaps it's a theming issue.
Yavor Georgiev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.