ApachePOI生成org.apache.poi.POIXMLException:java.lang.reflect.InvocationTargetException
使用Apache POI创buildExcel工作表时,我有时会遇到以下exception
ApachePOI generates org.apache.poi.POIXMLException: java.lang.reflect.InvocationTargetException
它经常发生在一个相当简单的代码添加之后,比如下面的代码:
Row myRow= CellUtil.getRow(1, xlsMainTable); CellUtil.getCell(myRow, 10).setCellValue(d.getParamStr());
因此,对于未正确安装的库而言,这不成问题。
如果setCellValue()
有一个空值,这经常发生在我身上
如果你防止setCellValue
被提供空值,那么这个问题应该消失。