I have a RadGridView bound to a collection that is owned by an object on the viewmodel that can change instances at runtime. When the app launches, it populates this collection for each of the instances of this class.
<telerik:RadGridView ItemsSource="{Binding SelectedProject.StandardProjectMilestones}" Grid.Row="0" x:Name="StandardMilestonesGridView"... />
My ViewModel implements the INotifyPropertyChanged "OnPropertyChanged" on the "SelectedProject" property. The "SelectedProject" is a "Project" object, which also implements "OnPropertyChanged" on the "StandardProjectMilestones" property, which is of type QueryableCollectionView. This collection is filtered from an Autoloading QueryableDomainServiceCollectionView of a RIA-loaded Enity Set. The grid gets populated with the initial "SelectedProject"'s collection, but when the "SelectedProject" is set to a different Project instance, whose "StandardProjectMilestones" collection has been pre-populated as I said, the collection data does not appear in the GridView - it just displays an empty grid. Even when the project is set back to the original Project, the grid remains empty. I tried repopulating the collection when the SelectedProject changes, but the same behavior occurs. Is there a re-binding that I need to do to get the grid to populate with the collection data when the object intance is reset? If so, how? Or is my design faulty somehow?
I should mention that in debugging I have verified that every Project's collection has items in it, they just don't show up on the gridview.
Thank you,
-Thomas
<telerik:RadGridView ItemsSource="{Binding SelectedProject.StandardProjectMilestones}" Grid.Row="0" x:Name="StandardMilestonesGridView"... />
My ViewModel implements the INotifyPropertyChanged "OnPropertyChanged" on the "SelectedProject" property. The "SelectedProject" is a "Project" object, which also implements "OnPropertyChanged" on the "StandardProjectMilestones" property, which is of type QueryableCollectionView. This collection is filtered from an Autoloading QueryableDomainServiceCollectionView of a RIA-loaded Enity Set. The grid gets populated with the initial "SelectedProject"'s collection, but when the "SelectedProject" is set to a different Project instance, whose "StandardProjectMilestones" collection has been pre-populated as I said, the collection data does not appear in the GridView - it just displays an empty grid. Even when the project is set back to the original Project, the grid remains empty. I tried repopulating the collection when the SelectedProject changes, but the same behavior occurs. Is there a re-binding that I need to do to get the grid to populate with the collection data when the object intance is reset? If so, how? Or is my design faulty somehow?
I should mention that in debugging I have verified that every Project's collection has items in it, they just don't show up on the gridview.
Thank you,
-Thomas