I am using an UltraControlContainer to host a custom user control. Essentially the user control shows a decimal value for one column in different currency formats depending on the currency code that exists in another column on the grid. The UltraControlContainer is set as the Editor for an unbound column. This columns data type is a custom type (MultiCurrencyValue) which contains both the currency code and decimal amount. I want to show a summary amount for this column (positioned under this column). Can this be acheived using a custom summary formula?
So you know, I do in fact have the "raw" decimal amount of this MultiCurrencyValue in another column in the grid. I was thinking I could use the unbound column as the position column, but show the sum of this "raw" decimal column.
Your thoughts?
Hi,
Yes, you could apply a Summary that is positioned with the unbound column, but sums up the values in the "raw" decimal column.
The column to which the summary is aligned has nothing to do with the formula or the the column whose data is being summed up.
private void ultraGrid1_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e) { UltraGridLayout layout = e.Layout; UltraGridBand band = layout.Bands[0]; band.Summaries.Add("Sum([raw])", SummaryPosition.UseSummaryPositionColumn, band.Columns["Unbound"]); }