Previously I was using POI 3.1.7 with setCellFormula without any issues. Now I've migrated to 4.1.1 and noticed that although the cell sets the formula correctly, it doesn't display any value (e.g the cell is set to "Accounting" format, the cell shows =PRODUCT(I4*L4), on screen it shows $ - . The code is as follow:
XSSFCell cell = null;
cell = row.createCell(12);
cell.setCellFormula("PRODUCT(I"+(processingRow+1)+",L"+(processingRow+1)+")");
cell.setCellStyle(getCellStyle("ACCOUNTING", sheet, true,true, false,false));
By the way, I'm using it on Excel 2013 (which I don't think should have any impact?). If I were to go into the formula cell and press enter at the end of the formula, the value will only then be displayed as it should be. Am I missing something?