Hi,
We have a grid with a column named GP. We would like to make this the Average of two sums of two other columns, cost and sell.
I thought it should be this (totalCost/totalSell or the key's for two other summaries on the same grid)
.Formula = (AVG[totalSell()] - AVG([totalCost()]) / AVG([totalSell()]
However it does not work. Even if try a simple formula like
.Formula = SUM([gp])
I get just an empty grey square.
I am sure we are missing something simple
EXAMPLE
e.Layout.Bands[0].Summaries.Add("gpavg", SummaryType.Formula, e.Layout.Bands[0].Columns["gp"]); e.Layout.Bands[0].Summaries["gpavg"].Formula = "SUM([gp])";
Thanks,
M
Hello,
To implement formulas on your Grid, please drag the UltraCalcManager component from the Toolbox onto your form. This will extend the capabilities of all the controls on the form. WinGrid needs this component on the form in order to support the formulas.
Let me know if you have any questions. Sincerely,Sahaja KokkalagaddaAssociate Software Developer
Hi. Thank you for your response.
We do have (and did) have a calc manager on the form. Can you verify how the formula might look for what I am describing?
M.