Hello,
I am currently evaluating Aspose.Cells for java and I’ve found a difference in its behaviour when compared to Excel. When I run the following code:
public static void main(String[] someArgs) throws Exception
{
Workbook workbook = new Workbook(“test/Test001.xls”);
workbook.getSettings().setCalcMode(CalcModeType.MANUAL);
int sheet = 0;
int row = 0;
int col = 0;
System.out.println(workbook.getWorksheets().get(sheet).getCells().get(row, col).getStringValue());
workbook.calculateFormula();
System.out.println(workbook.getWorksheets().get(sheet).getCells().get(row, col).getStringValue());
workbook.save(“test/Test001-result.xls”, FileFormatType.EXCEL_2003_XML);
}
On the attached spreadsheet (which contains in cell Sheet1!A1 an invalid reference to another cell) I get the following output:
#REF!
0
Basically the workbook originally (from Excel) contains a #REF!, and the saved resulting workbook contains a #REF! when recalculated in Excel, but a recalc in Aspose results in a zero.
Should Aspose.Cells match Excel’s behaviour as close as possible?