I am having difficulty moving to the new process. I didn't have to change much using POI 3.7 (just removed the (short) casting) to replace the deprecated with the new methods, like row.getCell(). Yet, on the
Busy Developer's Guide to HSSF and XSSF Features (
https://coderanch.com/forums/jforum?module=posts&action=insert&forum_id=45 ), it shows the deprecated values.
Anyway, when I upload a 97-2003 format spreadsheet (xls), I am erroring out on the line
. It doesn't even hit the catch, just goes straight to an error with the explanation
Caused by: java.lang.NoSuchMethodError: org/apache/poi/hssf/usermodel/HSSFRow.getCell(I)Lorg/apache/poi/hssf/usermodel/HSSFCell;
followed by
javax.servlet.ServletException: org/apache/poi/hssf/usermodel/HSSFRow.getCell(I)Lorg/apache/poi/hssf/usermodel/HSSFCell;
.
The reason I bring this up is because I was converting to use 2007+ .xlsx format spreadsheets and I was getting strange errors uploading those (and this got caught in the try/catch):
Unable to process spreadsheet: Invalid header signature; read 1688935826934608, expected -2226271756974174256
.
When I looked up the error, everything said you had to update to POI 3.5 or later (I have 3.7), so I'm stumped. By both errors, actually. I stripped all formatting just to be certain that there was nothing funny in the spreadsheets that couldn't be handled. Help.