I encountered this fun little problem while creating an XSSFWorkbook.
Calling cell.setCellType(CELL_TYPE_FORMULA) before
cell.setCellFormula() caused the following exception:

java.lang.IndexOutOfBoundsException
        at org.apache.xmlbeans.impl.store.Xobj.remove_attribute(Xobj.java:2269)
        at 
org.openxmlformats.schemas.spreadsheetml.x2006.main.impl.CTCellImpl.unsetT(Unknown
Source)
        at org.apache.poi.xssf.usermodel.XSSFCell.setCellType(XSSFCell.java:650)


Moving the setCellType() call after the setCellFormula() call resolved
the problem.

Cheers,
Karim

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to