GridView Distinct Filter Issue on ItemsSource reload

4 posts, 0 answers
  1. Barnes
    Barnes avatar
    17 posts
    Member since:
    May 2012

    Posted 28 Nov 2013 Link to this post

    Hi,

    I have an issue with  the grid view control. I have a databound observable collection as the items source for it. When I select distinct filters the grid filters fine.

    When I update the items source observable collection in the viewmodel and notify the UI, the grid is reloaded with only the rows that match the previously selected distinct filter. The distinct filter list only shows the distinct items that were selected before the items source was reloaded.

    I could quite easily clear the filters in the dataloading event handler but I want the filters that were selected to be maintained after the data has been reloaded. Please let me know if there is something I need to do to achive this.

    Thanks.
  2. Barnes
    Barnes avatar
    17 posts
    Member since:
    May 2012

    Posted 02 Dec 2013 Link to this post

    Hi,

    Any chance of an answer on this? 

    Thanks.
  3. DevCraft banner
  4. Barnes
    Barnes avatar
    17 posts
    Member since:
    May 2012

    Posted 02 Dec 2013 Link to this post

    Hi,

    Any chance of an answer on this? 

    Thanks.
  5. Dimitrina
    Admin
    Dimitrina avatar
    3769 posts

    Posted 02 Dec 2013 Link to this post

    Hello,

    You say that you update the ItemsSource observable collection in the viewmodel. Then a CollectionChange notification of the collection should be raised. 

    Then the filters should be applied over the entire data (the old one and the newly added one). 
    The DistinctFilters list should be also updated.

    What is the action (NotifyCollectionChangedAction) when the CollectionChanged event is raised? 

    Regards,
    Didie
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
Back to Top