DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=42564>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=42564


[EMAIL PROTECTED] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|WORKSFORME                  |




------- Additional Comments From [EMAIL PROTECTED]  2008-02-11 00:30 -------
Hello All, 

The problem:
I've just attached an 'empty' spreadsheet which throws an Exception when opening
(doesntwork.xls).

The stack trace is slightly different to the one originally posted here, but it
looks to be the same cause.

The Exception came from using versions: 3.0.2-FINAL-20080204 and the latest SVN
trunk build from Feb. 7th, 2008 (appologies, I am having SVN firewall probs.
here at work and can't get a later version at the moment).

Expected behaviour:
Well, that it opens and process correctly.

To replicate:
The test program I used to open the file was XLS2CSVmra.java found under:
/src/scratchpad/examples/src/org/apache/poi/hssf/eventusermodel/examples

I compiled and ran it under JDK 1.4.2.

Notes:
The Excel file was originally created by a client.  I removed : all data, all
named ranges, hidden worksheets, extra worksheets and macros, to leave the empty
spreadsheet attached.

Appologies if this bug has been resolved in a POI version post Feb. 7th; I won't
have subversion access to test the trunk until mid-week.

Many thanks as always! 

Dave

Stack trace:
[:/cygdrive/c/work/ExcelParser/42564/513] > javac XLS2CSVmra.java 
[:/cygdrive/c/work/ExcelParser/42564/514] > java -version
java version "1.4.2_03"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_03-b02)
Java HotSpot(TM) Client VM (build 1.4.2_03-b02, mixed mode)
[:/cygdrive/c/work/ExcelParser/42564/515] > java XLS2CSVmra ../doesntwork.xls 
org.apache.poi.hssf.record.RecordFormatException: Unable to construct record
instance
        at
org.apache.poi.hssf.record.RecordFactory.createRecord(RecordFactory.java:199)
        at
org.apache.poi.hssf.eventusermodel.HSSFEventFactory.genericProcessEvents(HSSFEventFactory.java:172)
        at
org.apache.poi.hssf.eventusermodel.HSSFEventFactory.processEvents(HSSFEventFactory.java:98)
        at
org.apache.poi.hssf.eventusermodel.HSSFEventFactory.processWorkbookEvents(HSSFEventFactory.java:63)
        at XLS2CSVmra.process(XLS2CSVmra.java:111)
        at XLS2CSVmra.main(XLS2CSVmra.java:324)
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:187)
        ... 5 more
Caused by: org.apache.poi.hssf.record.RecordFormatException: Unknown grbit '16'
        at
org.apache.poi.hssf.record.formula.ArrayPtg.readTokenValues(ArrayPtg.java:99)
        at
org.apache.poi.hssf.record.formula.Ptg.createParsedExpressionTokens(Ptg.java:110)
        at org.apache.poi.hssf.record.NameRecord.fillFields(NameRecord.java:778)
        at org.apache.poi.hssf.record.Record.<init>(Record.java:55)
        at org.apache.poi.hssf.record.NameRecord.<init>(NameRecord.java:139)
        ... 10 more
Exception in thread "main"  




-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to