Bug 29982

Summary: Unable to read spreadsheet when dropdown list cell is selected - Unable to construct record instance
Product: POI Reporter: Michael Richards <michael.richards>
Component: HSSFAssignee: POI Developers List <dev>
Status: RESOLVED FIXED    
Severity: major CC: bradleyjames
Priority: P3    
Version: 2.5-FINAL   
Target Milestone: ---   
Hardware: PC   
OS: All   
Attachments: Spreadsheet that causes the error described. Notice that the selected cell is a drop down list validation cell.
With this File the Bug can be simulated.

Description Michael Richards 2004-07-08 18:42:20 UTC
This problem occurs on a spreadsheet that has cells that have data validation 
from a drop down list.  The error occurs when one of the drop down list cells 
is selected on the spreadsheet.  If any other cell is selected, the spreadsheet 
can be processed without a problem.

I would attach the spreadsheet that causes the error, but I don't see that 
option provided in Bugzilla.  I can mail the spreadsheet to the owner of this 
bug upon request.

Here is the error that occurs:

org.apache.poi.hssf.record.RecordFormatException: Unable to construct record 
instance, the following exception occured: null
	at org.apache.poi.hssf.record.RecordFactory.createRecord
(RecordFactory.java:237)
	at org.apache.poi.hssf.record.RecordFactory.createRecords
(RecordFactory.java:160)
	at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
(HSSFWorkbook.java:165)
	at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
(HSSFWorkbook.java:132)
Comment 1 Michael Richards 2004-07-08 18:44:58 UTC
Created attachment 12063 [details]
Spreadsheet that causes the error described.  Notice that the selected cell is a drop down list validation cell.
Comment 2 Joao 2005-10-04 16:07:01 UTC
Created attachment 16586 [details]
With this File the Bug can be simulated.

With this File the Bug can be simulated.
Comment 3 Joao 2005-10-04 16:11:49 UTC
There's a new file submited where the error can be simulated.
Comment 4 surendra boganatham 2006-08-29 10:29:03 UTC
I have seen if you select all cells after touching or editing drop downs and
save, the excel is readable. could be temporary fix until the bug is fixed. 



(In reply to comment #0)
> This problem occurs on a spreadsheet that has cells that have data validation 
> from a drop down list.  The error occurs when one of the drop down list cells 
> is selected on the spreadsheet.  If any other cell is selected, the spreadsheet 
> can be processed without a problem.
> 
> I would attach the spreadsheet that causes the error, but I don't see that 
> option provided in Bugzilla.  I can mail the spreadsheet to the owner of this 
> bug upon request.
> 
> Here is the error that occurs:
> 
> org.apache.poi.hssf.record.RecordFormatException: Unable to construct record 
> instance, the following exception occured: null
> 	at org.apache.poi.hssf.record.RecordFactory.createRecord
> (RecordFactory.java:237)
> 	at org.apache.poi.hssf.record.RecordFactory.createRecords
> (RecordFactory.java:160)
> 	at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
> (HSSFWorkbook.java:165)
> 	at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>
> (HSSFWorkbook.java:132)

Comment 5 Avik Sengupta 2007-01-16 01:38:23 UTC
Works as of 12Jan2007, Testcase added. 
http://issues.apache.org/bugzilla/show_bug.cgi?id=41366