I didn't download 1.2.0, however when I removed the
graphs, the problems disappeared.  

I think that solves pretty much all of my current
problems, although I do have one more question.

Is there any easy way to work with columns, instead of
rows?  For example, say I have a big sheet full of data
(such as the one I uploaded as a problematic sample,
less the graphs of course) and I wanted to write a
program that would calculate the average of every
single column, and add it to the bottom of the column. 
I would think that if this sheet were organized such
that instead of having columns of data, it had rows, I
could just go through a HSSFRow's cells, and average
them.  With a column, I need to access a different row
every time I want to move down in the column.  Is there
an easier way to do this?

Thanks again for all the help,
Russell Stadler

"Andrew C. Oliver" wrote

> 
> Assigning Glen to look at this.  The sample has
embedded graphs.
> 
> Tested with reasonably recent build and it still
failed.
> 
> Russell,
> 
> POI::HSSF 1.0.2 will not handle embedded graphs, they
are treated as
> separate sheets within sheets and it has no idea what
to do with them. 
> Glen has new code to handle graphs in the current
development build.
> 
> Download the latest development build and try them
with it.  I'll do so
> shortly, but I don't have time to finish right now
(meeting someone).  
> 
> If you remove the graphs it should work fine. 
Regardless this shouldn't
> throw an exception (at the very least) in the latest
development build.
> 
> ccing glen.
> 
> -Andy
> 
> On Mon, 2002-01-28 at 12:12, [EMAIL PROTECTED]
wrote:
> > Hello again,
> > 
> > My apologies for the inadequate information.  The
> > version of POI is 1.0.2.  I thought it was all .xls
> > files, however it turns out I am mistaken.  I had a
> > number of sample files I was working with, which
were
> > all files that had been exported from Radview's
WebLoad
> > software.  When I filled in a few cells manually in

> > sheet, it worked fine.
> > 
> > I've uploaded both the .xls I created, and one of
the
> > .xls files that failed http://www.qxfr.com/poi.  The
> > one that works is named ok.xls, the other is named
> > problem.xls
> > 
> > Based on what you've said, I think it's either 1 or
2. 
> > I can view the workbook in Excel (2000) fine, so I
> > think that it's not a result of number 3.  It could
be
> > a result of 4 or 5, but I'm doubtful, because it did
> > work fine with the workbook I just filled a little
with
> > gibberish.  
> > 
> > I don't know how I would check if the XLS files are
> > encrypted or not in proper format.  Additionally, I
> > would like to know if it is possible to unprotect a
> > file, or convert it into proper excel format.
> > 
> > If it's at all helpful, I uploaded the source to a
> > little test program that reproduces this problem
with
> > the problem.xls file.
> > 
> > Thanks for your help,
> > Russell Stadler
> > 
> > 
> > "Andrew C. Oliver" wrote
> > 
> > > 
> > > What version of POI is this?  1.0.2 or 1.2.0. 
Please
> > provide a
> > > sample xls if possible.  This is not really
> > sufficient data? 
> > > Is it ONLY on this XLS or on all XLS?  
> > > 
> > > Here are some wild guesses
> > > 
> > > 1. The sheet is "protected" (which is a
Microsoftism
> > for encrypted)
> > > 2. The sheet is not in (proper) Excel 97 format
(For
> > example StarOffice
> > >    5.1 creates basically a cross-hybrid between 97
> > and 95 format...which
> > >    Excel 97 can read but later versions of Excel
> > officially cannot and
> > >    HSSF ONLY plans to support 97+)
> > > 3. The Workbook is invalid
> > > 4. you've stumbled upon something HSSF doesn't
> > support (in which case a
> > > sample would be REALLY appreciated)
> > > 5. There is a bug in HSSF that you've uncovered
(see
> > #4).
> > > 
> > > In any case a sample XLS or more information
would be
> > awesome!
> > > 
> > > -Andy
> > > 
> > > On Mon, 2002-01-28 at 00:02, [EMAIL PROTECTED]
> > wrote:
> > > > Hello,
> > > > 
> > > > When executing the line
> > > > 
> > > > HSSFWorkbook workbook = new HSSFWorkbook(poifs);
> > > > 
> > > > with poifs being an existing POIFSFileSystem
created
> > > > from an inputstream, I recieve the following
> > exception:
> > > > 
> > > >
----------------------------------------------------
> > > > java.lang.NullPointerException
> > > > 
> > > >         at
> > > >
> >
net.sourceforge.poi.hssf.usermodel.HSSFSheet.setPropertiesFromSheet(HSSFSheet.java:184)
> > > > 
> > > >         at
> > > >
> >
net.sourceforge.poi.hssf.usermodel.HSSFSheet.<init>(HSSFSheet.java:142)
> > > > 
> > > >         at
> > > >
> >
net.sourceforge.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:159)
> > > >
----------------------------------------------------
> > > > 
> > > > Any help would be greatly appreciated.
> > > > 
> > > > -Russell Stadler
> > > -- 
> > > www.superlinksoftware.com
> > > www.sourceforge.net/projects/poi - port of Excel
> > format to java
> > >
> >
http://developer.java.sun.com/developer/bugParade/bugs/4487555.html 
> > >                   - fix java generics!
> > > 
> > > 
> > > The avalanche has already started. It is too late
for
> > the pebbles to
> > > vote.
> > > -Ambassador Kosh
> > 
> > 
> > 
> > ------------------------------------------
> > [EMAIL PROTECTED]
> -- 
> www.superlinksoftware.com
> www.sourceforge.net/projects/poi - port of Excel
format to java
>
http://developer.java.sun.com/developer/bugParade/bugs/4487555.html 
>                       - fix java generics!
> 
> 
> The avalanche has already started. It is too late for
the pebbles to
> vote.
> -Ambassador Kosh



------------------------------------------
[EMAIL PROTECTED]

Reply via email to