I use a numeric updown control to allow the users to adjust numeric values to effect a change in my ultragrid. In my ultragrid InitializeLayout event I have the following:
... var band = e.Layout.Bands[0]; band.Columns["CalcMarkup"].Formula = "if ([Markup] > 0, [FinalCost]*([Markup]/100), 0)"; band.Columns["RemainingCost"].Formula = "if([CalcMarkup] > 0, 0, [FinalCost] )"; band.Columns["ForcedMarkup"].Formula = "if([RemainingCost] = 0, 0, ([RemainingCost]/[sumRemCost()])*[force()])"; ... grdMain.DisplayLayout.Bands[0].Summaries.Add("force", "[ForcedAdj()]", SummaryPosition.UseSummaryPositionColumn, grdMain.DisplayLayout.Bands[0].Columns["ForcedMarkup"]); ... var value = 1 - (nudMarginPer.Value/100); _marginFormula = string.Format("( ( ([finCost()]/{0})-sum([FinalCost]) )-sum([CalcMarkup])-5000000 )", "{0}"); band.Summaries.Add("ForcedAdj", string.Format(_marginFormula, value)); band.Summaries["ForcedAdj"].SummaryDisplayArea = SummaryDisplayAreas.None; ... grdMain.DisplayLayout.Bands[0].Summaries.Add("force", "[ForcedAdj()]", SummaryPosition.UseSummaryPositionColumn, grdMain.DisplayLayout.Bands[0].Columns["ForcedMarkup"]);in the numeric updown event: void nudMarginPer_ValueChanged(object sender, EventArgs e) { var value = 1 - (nudMarginPer.Value/100); grdMain.DisplayLayout.Bands[0].Summaries["ForcedAdj"].Formula = string.Format(_marginFormula, value); }
This works well in that when the user presses the updown buttons the summary (ForceAdj) values change and is reflected in the grid summary row. However the column formula for ForcedMarkup doesnt change until a second button press. So now the summary is correct however the value in the cell is off.
My question is this... How do I force the formula for ForcedMarkup (or any column formula) to refresh to reflect the current calcs?
I have tried forcing a grid update, calcmanager recalc, etc... nothing seems to work. I have attached a zip file containing the form.
thanks
Hello Jeff,
On the following link you could see the list of Infragistics versions which are supported for service releases:
http://es.infragistics.com/help/product-lifecycle
Please see my response in your private case, where I’ve already explained the options of patch.
Please let me know if you have any issues to access your case.
As I mentioned earlier ... we are using version 13.1.
thanks!
Could you please verify the product version of the Infragistic’s components you’re currently using, in order to our engineering stuff to create a patch resolving your issue for the version you’re using.
Please let me know for which exactly version you want a pact.
I am waiting for your feedback.
Thanks for the reply. I would like to remind you I’ve created case for you in our issue tracking system, its id is CAS-140737-L8Y4B0,so please when you have some questions concerning the bug please ask them through the issue tracking system. I will really appreciate that. As you don't have a deadline as soon as our engineering staff end their examination of the issue you'll be immediately informed.
I dont necessarily have a deadline nor is this too much of an issue as I am using a working around (dont use groups). However at some point I would like to implement grouping because it will be easier for our users to handle their data better.