Reputation: 305
I have custom DataGridTemplateColumn. I'm trying to merge the column in RowSizeChangedEvent by setting the margin. I have few rows and some of the rows will be duplicated. I would like to merge those rows in column level. Each rows has Actual Height as 30. When i'm getting duplicate rows, i'm setting the margin for last duplicated row in negative value of top margin
For example
Expected
I have set currentcell margin for last duplicated row: (0,-(sum of duplicate row-Actual height of currentcell,0,0) in Row size changed event. It is working as expected at first time. 2nd time if i reloading that grid, it got failed. But margin size is as expected. I have tried InvalidateVisual() and UpdateLayout() methods. Not useful.
Note: dynamically generating columns
Thanks!
Upvotes: 0
Views: 130