Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
965
Force Summary Row Formula Recalculation after a Group By
posted

Hello,

I am using version 14.1. Some columns in my grid use formulas to build the summary row. They are rather simple and just combine values from other columns. After the grid is filtered or grouped I need to recalc the formulas.

I have the filtering working good but can't seem to get the recalc to work after the grid is grouped.

Here is the code I use after a filter. Please advise on how to pull this off after a grouping.


private void ugGrid1_AfterRowFilterChanged ( object sender, AfterRowFilterChangedEventArgs e )
{
			UltraGrid ugGrid = (UltraGrid)sender;
			UltraGridBand Band = ugGrid.DisplayLayout.Bands[0];
 
			RecalcTwoFieldString( Band, ugGrid );
}

public static void RecalcTwoFieldString ( UltraGridBand Band, UltraGrid ugGrid )
{
		Band.Summaries["TwoFieldString"].DisplayFormat = ugGrid.Rows.SummaryValues["TwoField1"].Value.ToString() + "/" + ugGrid.Rows.SummaryValues["TwoField2"].Value.ToString();
}
Parents
No Data
Reply
  • 29085
    Offline posted

    Hello,

    I hope Mike's response has helped you. If at any point you have any questions please do not hesitate to ask.

Children
No Data