Home › Forums › WinForms controls › Xceed Grid for WinForms › Xceed Grid for .Net – child rows border aren’t displayed corectly. › Reply To: Xceed Grid for .Net – child rows border aren’t displayed corectly.
I haven’t try your code, nor have I tried to re-work it, but one thing you need is first setup the grids in the form load event, and add rows only after this is done. The reason is that the DetailGridTemplates property that you set in the first InitializingDetailGrid event is, as its name implies, a template, and you constantly change it (every time the event is triggered), and then update the whole grid with it when calling UpdateDetailGrids().
So set up the grid and both detail grids only once in form_load, including the subscribing to both InitializingDetailGrid events, then add rows to the main grid. This will trigger the first InitializingDetailGrid event, in which you can still add your columns and use e.Grid to add rows to this detail grid. In turn, this will trigger the second InitializingDetailGrid event, again in which you add columns and rows for that detail grid.
One more thing. If you set the ColumnManagerRow visible property to false, and to not change it later in your application, you don’t need to create and add one to the detail grids.
Imported from legacy forums. Posted by André (had 351 views)