Does Aspose.Cells support auto calculation of Formulas (just like Excel does) - e.g. I have:
Hi Nick,
Thanks for your posting and using Aspose.Cells for Java.
Aspose.Cells does not support automatic calculation. You need to call calculateFormula() to trigger formula calculation using Aspose.Cells. It might be a complex feature or may slow down Aspose.Cells processing.
However, I have logged your feature request in our database. We will look into it and update you. Once, there is some fix or news for you, we will let you know asap.
This issue has been logged as CELLSJAVA-40740.
WorkbookSettings settings = wb.getSettings();
settings.setCalcMode( CalcModeType.AUTOMATIC );
This actually sets the calculation mode of MS-Excel for the output xls/xlsx file to automatic or manual. It does not make Aspose.Cells to automatically calculate the formula.
We cannot do such kind of operation automatically because it may cause performance issue for most users. For your requirement, we think you should enable the formula calculation chain by setting Workbook.Settings.CreateCalcChain as true. Then you may call Workbook.CalculateFormula() anywhere and anytime before getting one cell’s value which may need to be re-calculated. With the calculation chain, we only calculate those formulas that need to be re-calculated according to their precedents that have been changed.