So, I've resolved my issue.  I've decided to post the resolution to confirm
the fact that it's not a bug, and to provide some insight to others who
might not want to output their HSSFWorksheet to a filesystem directly.
My problem was that even though I'm not writing to a FileOutputStream, you
still to do a HSSFWorksheet.write(), in order to create the POIFSFileSystem.
So, when I was attaching by Workbook to my mail message, I was attaching the
Worksheet Object.  The proper thing to do is write the worksheet to a
ByteArrayOutputStream, and attach that.

    ByteArrayOutputStream WorkbookStream = new ByteArrayOutputStream();
    Workbook.write(WorkbookStream);
    WorkbookAttachment = WorkbookStream.toByteArray();

Thanks to everyone (especially Jason) for helping.

Curtis



-----Original Message-----
From: Height, Jason [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 29, 2004 4:47 PM
To: 'POI Developers List'
Subject: RE: HPSF Mutables 


Curtis,

Your shouldn't have to manually attach properties, at least unless something
has radically changed.

Could you dummy up a simple test and write the sheet to a file instead of a
mime attachment. Maybe something is going wrong with mime. If it is still a
problem then please create a bug in bugzilla, attaching both the errornous
excel file and a code snippet to create the file.

FYI I have never seen this problem in my use of HSSF.

Jason

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

Reply via email to