Beats me, had lots of diffs and stuff.
So using 2.0.x achieved the same as the diffs I posted. I assume 3.0
probably tries to fix problems with the
imaging code. I'm having you comment it out :-). POI should leave
records it doesn't understand where they lie.
Thus I suspect that will make Excel happy.
-Andy
[EMAIL PROTECTED] wrote:
Ah thanks, I found your post now (9th July):
There are problems with
*reading* images in the 2.5 series. It writes them just fine, just
has issues reading them. Drop to 2.0.x. Shortly I'll add a "ignore
images" bit twiddle if no one beats me to it.
In that post you were talking about the InvocationTargetException on
loading a workbook.
Just to say, that problem went away when I tried today's 3.0 nightly
build. (Or, at least, it didn't throw anything...) But when I saved
using POI and reloaded in Excel, it complained of 'integrity problems'
and discarded the PivotTable.
(Maybe I should try 2.0.x also...)
Iain
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: 01 August 2005 14:34
To: poi-user@jakarta.apache.org
Subject: Re: POI pivot tables
I posted awhile back on changes that can be made to the record factory
for (ignoring) images. Those same changes would seem to apply here.
Doing it in an API fashion via some toggle of sorts is on my list of
todos.
[EMAIL PROTECTED] wrote:
Hello all,
Apologies, I know similar questions come up often. However I have
looked in the archives and bugzilla, and I haven't found anything that
seemed directly relevant.
I was trying to open a (Excel 2002) XLS which contains a pivot table.
I was hoping to just fill in data, and when I re-opened Excel, it
would refresh the pivot table.
Trying this with POI 2.5.1 gives:
java.lang.reflect.InvocationTargetException
...
at
java.lang.reflect.Constructor.newInstance(Constructor.java:274)
at
org.apache.poi.hssf.record.RecordFactory.createRecord(RecordFactory.ja
va
:224)
at
org.apache.poi.hssf.record.RecordFactory.createRecords(RecordFactory.jav
a:160)
at
org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:163)
...
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:57)
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)
which I think is a known issue?
So, I've tried poi-3.0-alpha1-20050801.jar.
This doesn't give any error. But when I load the file in Excel (2002
SP3), it discards the PivotTable 'due to integrity problems'.
Can POI be used in this way? Is it a known problem?
Appreciate any advice.
Iain Shepherd
----------------------------------------------------------------------
--
For more information about Barclays Capital, please
visit our web site at http://www.barcap.com.
Internet communications are not secure and therefore the Barclays
Group does not accept legal responsibility for the contents of this
message. Although the Barclays Group operates anti-virus programmes,
it does not accept responsibility for any damage whatsoever that is
caused by viruses being passed. Any views or opinions presented are
solely those of the author and do not necessarily represent those of
the
Barclays Group. Replies to this email may be monitored by the
Barclays
Group for operational or business reasons.
----------------------------------------------------------------------
--
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
Mailing List: http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project: http://jakarta.apache.org/poi/ .
--
Andrew C. Oliver
SuperLink Software, Inc.
Java to Excel using POI
http://www.superlinksoftware.com/services/poi
Commercial support including features added/implemented, bugs fixed.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
Mailing List: http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project: http://jakarta.apache.org/poi/