Home Forums WinForms controls Xceed Grid for WinForms Sorting a detail grid programatically.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • User (Old forums)
    Member
    Post count: 23064
    #14373 |

    I have a master/detail grid that I bind to a Dataset. Everything works fine with that. When i click on the header in the detail grid it sorts like I would expect. How do I programatically do this?

    I was trying something like.

    Dim mydtgrid As DetailGrid
    mydtgrid = Me.GridControl1.DetailGridTemplates(0)
    mydtgrid.Columns(1).SortDirection = Ascending

    it tells me my detail grid doesn’t have any columns even though it does.

    Any help?

    Thanks

    Imported from legacy forums. Posted by wcombs (had 1912 views)

    User (Old forums)
    Member
    Post count: 23064

    The way in which I’ve done it is to add the rows I want to sort on into the SortedRows property of the detail grid you’re interested in.

    Imported from legacy forums. Posted by Chris (had 2974 views)

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.