You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2008/11/19 02:08:44 UTC
DO NOT REPLY [Bug 46235] New: Unable to construct record instance
https://issues.apache.org/bugzilla/show_bug.cgi?id=46235
Summary: Unable to construct record instance
Product: POI
Version: 3.1
Platform: PC
OS/Version: Windows Server 2003
Status: NEW
Severity: major
Priority: P2
Component: HSSF
AssignedTo: dev@poi.apache.org
ReportedBy: yesj@nttdatabj.com.cn
Hello,
with the version 3.1.0 of POI I can do this code :
ByteArrayInputStream instream_ = null;
POIFSFileSystem fs = null;
POIManagerFactory managerFactory = null;
try {
workbook = null;
instream_ = new ByteArrayInputStream(_byteFile);
fs = new POIFSFileSystem(instream_);
workbook = new HSSFWorkbook(fs);
instream_.close();
instream_ = null;
fs = null;
} catch (Exception e) {
throw new SystemException(e.getMessage(), e);
}
However, when I want to open the attachment file, exception occurred,
other file is possible .
workbook = new HSSFWorkbook(fs);
// Exception with 3.1 no probleme with 2.5
I use for POI 3.1 :
poi-3.1-FINAL-20080629.jar
poi-contrib-3.1-FINAL-20080629.jar
poi-scratchpad-3.1-FINAL-20080629.jar
The Exception is :
Caused by: org.apache.poi.hssf.record.RecordFormatException: Unable to
construct record instance
at
org.apache.poi.hssf.record.RecordFactory.createRecord(RecordFactory.java:208)
at
org.apache.poi.hssf.record.RecordFactory.createRecords(RecordFactory.java:126)
at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:246)
at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:169)
at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:151)
at
jp.co.nttdata_chugoku.sprist.scm.common.comservice.POIManagerImpl.getHSSFWorkbook(POIManagerImpl.java:53)
at
jp.co.nttdata_chugoku.sprist.scm.common.comservice.MakeExcelCom.<init>(MakeExcelCom.java:150)
... 59 more
Caused by: java.lang.reflect.InvocationTargetException
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:274)
at
org.apache.poi.hssf.record.RecordFactory.createRecord(RecordFactory.java:196)
... 65 more
Caused by: org.apache.poi.hssf.record.RecordFormatException: Expected continue
record.
at org.apache.poi.hssf.record.UnicodeString.fillFields(UnicodeString.java:236)
at org.apache.poi.hssf.record.UnicodeString.<init>(UnicodeString.java:115)
at
org.apache.poi.hssf.record.SSTDeserializer.manufactureStrings(SSTDeserializer.java:49)
at org.apache.poi.hssf.record.SSTRecord.fillFields(SSTRecord.java:364)
at org.apache.poi.hssf.record.Record.<init>(Record.java:55)
at org.apache.poi.hssf.record.SSTRecord.<init>(SSTRecord.java:101)
NB : the file that I open is on my station.
Sincerely
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org
DO NOT REPLY [Bug 46235] Unable to construct record instance
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=46235
Josh Micich <jo...@gildedtree.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
--- Comment #1 from Josh Micich <jo...@gildedtree.com> 2008-11-18 18:24:07 PST ---
There have been some recent changes/fixes in ContinueRecord processing. Try
with POI 3.2
If the problem is still present, please re-open this bugzilla and upload a
sample workbook which causes the error.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org
DO NOT REPLY [Bug 46235] Unable to construct record instance
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=46235
--- Comment #2 from yesj <ye...@nttdatabj.com.cn> 2008-11-18 19:21:22 PST ---
Created an attachment (id=22890)
--> (https://issues.apache.org/bugzilla/attachment.cgi?id=22890)
sample workbook which causes the error
where I use poi3.2,the problem is still present, I have uploaded a
sample workbook which causes the error at this bugzilla.
Sincerely
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org