Created attachment 23247 [details] XLS file used for testing With r742126, I am getting exception while reading an xls file. Stack trace: org.apache.poi.hssf.record.RecordFormatException: Unable to construct record instance at org.apache.poi.hssf.record.RecordFactory.createSingleRecord(RecordFactory.java:226) at org.apache.poi.hssf.record.RecordFactory.createRecords(RecordFactory.java:352) at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:276) at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:201) at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:317) at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:298) at org.apache.poi.ss.usermodel.WorkbookFactory.create(WorkbookFactory.java:59) Caused by: org.apache.poi.hssf.record.RecordFormatException: Expected to find a ContinueRecord in order to read remaining 65535 of 65535 chars at org.apache.poi.hssf.record.RecordInputStream.readStringCommon(RecordInputStream.java:318) at org.apache.poi.hssf.record.RecordInputStream.readUnicodeLEString(RecordInputStream.java:273) at org.apache.poi.hssf.record.pivottable.ExtendedPivotTableViewFieldsRecord.<init>(ExtendedPivotTableViewFieldsRecord.java:57) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:494) at org.apache.poi.hssf.record.RecordFactory.createSingleRecord(RecordFactory.java:224) ... 41 more
Thanks for the sample file. It showed up another 3 bugs as well. Some were introduced due to edits made while applying patch for release 3.5-beta5 (bug 46301 , svn r721007 ). All four bugs were fixed and junits added in svn r743601 .
*** Bug 46892 has been marked as a duplicate of this bug. ***
*** Bug 47305 has been marked as a duplicate of this bug. ***