Home Forums WinForms controls Xceed Grid for WinForms Can I iterate thru detail grids to examine ColumnManagerRows

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

    How can I iterate through a master grid’s detail grids (And NOT using DetailGridTemplates)? My intention is to do something like the following:

    foreach detailGrid in MasterGrid
    {
    get ColumnMangerRow
    examine ColumnManagerRow for Column widths, order, etc. to persist off
    }

    Using the DetailGridTemplates doesn’t work since they don’t contain changes the user makes to column width/order/sorting, etc.

    Thanks in advance,
    Todd Berry

    Imported from legacy forums. Posted by tberry (had 1862 views)

    User (Old forums)
    Member
    Post count: 23064

    You’ll need to go through the datarows:
    foreach(Xceed.Grid.DataRow rowToCheck in Grid.DataRows)
    {
    if(0 != rowToCheck.DetailGrids.Count)
    {
    Xceed.Grid.Collections.ReadOnlyDetailGridList detailGrids = rowToCheck.DetailGrids;
    // Do what ever you want with the detail grids.
    }
    }

    // To resize all detail grids the same ensure that they are synchronized.

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

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