We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

GridControl FormulaCell not calculating

Hello, I have a Formula cell defined on my grid that is not calculating. The formula is a simple sum of cells, nothing complex. My GridControl object is setup so that I can dynamically add new rows to the GridControl as needed for input by the user. If the user adds a new row, the FormulaCell in the current location is cleared out and a new FormulaCell is added in the row below. When I add the new formula cell and then input numbers, the numbers are not summed. Additionally, I was able to call the model.RefreshRange to get the cell formula to work again, but the grid would crash and my cpu usage would rocket to 100% if I scrolled the GridControl. Help!! Thanks, -Paul

4 Replies

AD Administrator Syncfusion Team April 13, 2004 07:47 PM UTC

What version are you using? There is code in 2030 that can help reduce the 100% utilization problem. You say you clear the formula cell and then add it again. You might also try clearing the dependency tables too. GridFormulaEngine engine = ((GridFormulaCellModel) grid.CellModels["FormulaCell"]).Engine; engine.DependentCells.Clear(); engine.DependentFormulaCells.Clear();


AD Administrator Syncfusion Team April 14, 2004 12:53 PM UTC

I''m using 1.6.2.4 of the Suite. I''ll try your suggestion and let you know the outcome. Thanks, -Paul


PL Paul Laudeman April 14, 2004 06:06 PM UTC

No luck Clay. I tried your code and the formula still wouldn''t work. If I coupled your code with the call to RefreshRange, I got the runaway cpu usage issue. -Paul


AD Administrator Syncfusion Team April 14, 2004 06:52 PM UTC

You should try the 2.0.3.0 code base. It may help in this problem. If you can post a sample project showing the problem, I can try it here.

Loader.
Live Chat Icon For mobile
Up arrow icon