Bug 40738 - Excel autofilter problem
Summary: Excel autofilter problem
Status: RESOLVED FIXED
Alias: None
Product: POI
Classification: Unclassified
Component: HSSF (show other bugs)
Version: 2.5-FINAL
Hardware: PC Windows XP
: P2 major with 4 votes (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-10-12 00:43 UTC by Daniel Dacila
Modified: 2007-04-16 03:59 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Dacila 2006-10-12 00:43:18 UTC
The following code crashes at the 3rd line when Excel Autofilter is enabled.
Otherwise it works fine.

InputStream in = new ByteArrayInputStream(...);
POIFSFileSystem fs = new POIFSFileSystem(in);
HSSFWorkbook workbook = new HSSFWorkbook(fs);

The errorstack is this:
Caused by: java.lang.ArrayIndexOutOfBoundsException
        at java.lang.System.arraycopy(Native Method)
        at org.apache.poi.hssf.record.UnknownRecord.<init>(UnknownRecord.java:62
)
        at org.apache.poi.hssf.record.SubRecord.createSubRecord(SubRecord.java:5
7)
        at org.apache.poi.hssf.record.ObjRecord.fillFields(ObjRecord.java:99)
        at org.apache.poi.hssf.record.Record.fillFields(Record.java:90)
        at org.apache.poi.hssf.record.Record.<init>(Record.java:55)
        at org.apache.poi.hssf.record.ObjRecord.<init>(ObjRecord.java:61)

I think that the data parameter in the call to constructor is null.
Comment 1 Yegor Kozlov 2007-04-16 03:59:21 UTC
Works fine with the latest 3.0 RC .
If you have a particular xls file that still has autofilter problems, please
upload it and reopen this bug.

Yegor