My problem:
I merged the first column of a grid, where the value in this column only changes, say, every 100 rows.
band.Columns[0].SortIndicator = SortIndicator.Descending;band.Columns[0].MergedCellStyle = MergedCellStyle.OnlyWhenSorted;band.Columns[0].MergedCellEvaluationType = MergedCellEvaluationType.MergeSameText;
While scrolling, this value gets out of sight and out of mind :-( . This column seems to be empty now, until the next ((different) value appears.
Is it possible to keep the value on top of the column while scrolling until the next value appears?
Hi Mike,
this works alright , thanks for your help.
Oh, I see. I thought it did that by default, but it doesn't. You need to set the MergedCellContentArea property.
private void ultraGrid1_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e) { e.Layout.Override.MergedCellContentArea = MergedCellContentArea.VisibleRect; }
sorry, maybe I didn't describe my problem precisely enough, here again:
I'd like to keep the content of the merged column (always the same value) in focus while scrolling over loads of rows, which are all adherent to this certain value in the merged column. Looks like this:
1. column = merged, 2. column = details
|------| || | 1 | | | 2 | | | 3 | | A | 4 | | | 5 | | | 6 | | | 7 | | | 8 | | | 9 | | | 10 | | | 11 | | | 12 | | | 13 | | | 14 | | | 15 | | | 16 | | | 17 | |_________| | 1 | | | 2 | | | 3 | | B | 4 | | | 5 | | | 6 | | | 7 |
While scrolling downwards, "A" of the merged column gets out of sight, you can't see to which value the detailed values like "15", "16", "17" belong to (to "A").
Is it possible that "A" stays in the topmost but visible position, as long as any of its details (1 - 17) can be seen?
I thought the value stays centered in the column by default. Maybe you have to set MergedCellAppearance.TextVAlign.