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=34732>.
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=34732

           Summary: Word documents generated by FrameMaker 6/7  throw
                    ClassCastException
           Product: POI
           Version: 2.5
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: POIFS
        AssignedTo: [email protected]
        ReportedBy: [EMAIL PROTECTED]


Word documents generated by FrameMaker 6/7  throw ClassCastException

Unexpected Exception.
java.lang.ClassCastException
 at org.apache.poi.poifs.property.PropertyTable.<init>
    (PropertyTable.java:81)
 at org.apache.poi.poifs.filesystem.POIFSFileSystem.<init>
    (POIFSFileSystem.java:97)

Our immediate fix was to patch the constructor for
java.org.apache.poi.poifs.property.PropertyTable to throw an IOException instead
of the cce (so at least our app would handle it and not let the unchecked cce
kill us).  We did:

    if ((_properties.size() == 0) ||
        (!(_properties.get(0) instanceof DirectoryProperty)))
    {
        throw new IOException("No root directory property");
    }

But we still can't actually read the document.  It looks like FrameMaker creates
a structured storage with no root and no directory, but just the single stream
that contains the Word doc data.  Note that Word and OpenOffice can open these
documents without any problems.

-- 
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]
Mailing List:    http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta POI Project: http://jakarta.apache.org/poi/

Reply via email to