Programmatically Sorting a GridView

3 posts, 0 answers
  1. Frustrated Dev
    Frustrated Dev avatar
    35 posts
    Member since:
    Oct 2006

    Posted 06 Mar 2010 Link to this post

    Hello,

    I am using the Telerik RadGridView. One of my columns uses a custom Header. When a user clicks a specific set of text within this Header, I would like to sort the data in the RadGridView. Is there a way to programmatically sort the contents of a RadGridView? If so, how?

    Thank you,
  2. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 08 Mar 2010 Link to this post

    Hello Frustrated Dev,

    Indeed you can sort the grid programmatically - all you need is to add desired SortDescriptor in SortDescriptors collection.

    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. Frustrated Dev
    Frustrated Dev avatar
    35 posts
    Member since:
    Oct 2006

    Posted 08 Mar 2010 Link to this post

    But how do you add a SortDescriptor? I do not understand how they work and I have not seen any documentation for them.
Back to Top