Hi,
I have a WinGrid in which I am grouping by one column (fund in the attached image), although I am grouping I want to display this grid as if it has no grouping done. I want to show the sub total by grouped column. To do this I have set OutlookGroupBy on the grid and added the column in the sorted coulmn collection with group by parameter set. Also I set following properties
private void dgTrade_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e) { e.Layout.ViewStyleBand = ViewStyleBand.OutlookGroupBy; this.dgTrade.DisplayLayout.Bands[0].SortedColumns.Add("Fund", false, true); e.Layout.GroupByBox.Hidden = true; e.Layout.Override.HeaderPlacement= HeaderPlacement.FixedOnTop; }
GroupByRowExpansionStyle = Disabled;GroupByRowInitialExpansionState=Expanded;
I get the result as shown in the attached image. Is there a way to do the following
1) Hide the group Header Row (Where it says Fund: CCF (2 items)) [colored RED in the image]
2) Remove the Indentation [color: purple] so that Fund column perfectly left align to column header.
for first problem I tried the following code but did not worked
private void dgTrade_InitializeRow(object sender, InitializeRowEventArgs e) { if (e.Row.IsGroupByRow) { e.Row.Hidden = true; } }
For second part I tried
GroupByRowPadding=0;GroupByRowSpacingAfter=0;GroupByRowSpacingBefore=0;
Please advise.
Thanks Mike,
Well if I cannot hide the GroupByRow without hiding the child rows, then is there a way to format the title of the GroupByRow currently saying Fund: EMM (3 Items)
dverma said:1) Hide the group Header Row (Where it says Fund: CCF (2 items)) [colored RED in the image]
No. You can hide the GroupByRow, but not without hiding the child rows.
dverma said:2) Remove the Indentation [color: purple] so that Fund column perfectly left align to column header.
band.IndentationGroupByRow = 0;