List of filtered items?

9 posts, 0 answers
  1. Morgan McCollough
    Morgan McCollough avatar
    34 posts
    Member since:
    May 2010

    Posted 01 Sep 2010 Link to this post

    Does anyone know if there is an easy way to get at the list of items in the grid that match the current filter? It seems that the "Items" collection only gives you the items that are currently in the view area. I would like to do something like select all the items that match the current filter in order to perform some operation on them. Thanks in advance!

    Build: 2010.1.812.1040
  2. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 02 Sep 2010 Link to this post

    Hello,

     Generally Items will give you exactly the filtered (and sorted) items however in case of paging (not sure if this your case?) these filtered items will be paged.

    Greetings,
    Vlad
    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
  3. DevCraft banner
  4. Morgan McCollough
    Morgan McCollough avatar
    34 posts
    Member since:
    May 2010

    Posted 02 Sep 2010 Link to this post

    I was using the Items list to do something directly in the UI level. I was getting tripped up by a misunderstanding of row virtualization. The items list does work as expected. Thanks!
  5. gianluigi
    gianluigi avatar
    2 posts
    Member since:
    Jan 2011

    Posted 31 Jan 2011 Link to this post

    Hi,

    I need have the full list of filtered items in a paged GridView (the filtered items of all the pages) , how I can do this? The items only give me the list of visible rows-items


    Gianluigi
  6. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 01 Feb 2011 Link to this post

    Hi,

     Are you looking for your ItemsSource?

    Regards,
    Vlad
    the Telerik team
    Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
  7. gianluigi
    gianluigi avatar
    2 posts
    Member since:
    Jan 2011

    Posted 01 Feb 2011 Link to this post

    Hi,

    In the ItemSource I have all the items, I need only the filtered items but of all the pages, now I resolve removing the paging, get all the items and reapply the paging but is not a very beautiful solution

    Gianluigi
  8. Morgan McCollough
    Morgan McCollough avatar
    34 posts
    Member since:
    May 2010

    Posted 29 Mar 2011 Link to this post

    Is there a way to do this without turning off row virtualization? I think the ItemsSource only gives you the visible items if you have RowVirtualization set to 'true'...
  9. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 30 Mar 2011 Link to this post

    Hi Morgan McCollough,

     Actually ItemsSource is what you've assigned and this cannot be changed by RadGridView. You can use Items property of the grid - this will respect filtering, sorting, grouping, etc. 

    Best wishes,
    Vlad
    the Telerik team
  10. Morgan McCollough
    Morgan McCollough avatar
    34 posts
    Member since:
    May 2010

    Posted 30 Mar 2011 Link to this post

    Thanks for the quick response. Yeah, you can ignore that last post. I wasn't really thinking about what I was saying :)

    I think I was thinking about the behavior of the "Items" collection with RowVirtualization turned on or off. I think it was that with RowVirtualization turned on that collection only contained the items visible on the screen, but at this point I can't remember for sure. Just ignore me for now and I'll post again if I get to work with this again and have something more coherent to say :-)
Back to Top
DevCraft banner