Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1440
Positioning In Grid After Refresh
posted

I have a wingrid who's datasource is a dataset containing 3 datatables organized as a hiearachy.  When I make a change in the lowest level, I'd like to set that row as the active row and expand its parent levels after refreshing the grid and position the expanded display in the visible area of the grid.

I've come across numerious posts indicating that it can't be done but nothing official from Infragistics.  Please advise on how to do this?

Thank you

Clay Seifert

 

Parents
No Data
Reply
  • 469350
    Verified Answer
    Offline posted

    Hi Clay,

    I don't see any reason why this can't be done. If you have the data row (or whatever object your data source is using), then you should be able to find the corresponding row in the grid. It's a bit tricky to do this efficiently for a row three levels deep, but at the very least, you can loop through every row in the grid recursively and use the ListObject property on the grid row to compare to the data row you want.

    Once you find the row, it's simply a matter of walking up it's parent chain and expanding each parent row. Then you can use the ActiveRowScrollRegion.ScrollRowIntoView method.

Children
No Data