https://issues.apache.org/bugzilla/show_bug.cgi?id=56278

            Bug ID: 56278
           Summary: Workbook Opens in Excel But Not POI Due To NPE
           Product: POI
           Version: 3.10
          Hardware: PC
                OS: Mac OS X 10.4
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XSSF
          Assignee: dev@poi.apache.org
          Reporter: lei...@gmail.com

Created attachment 31395
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=31395&action=edit
File opens in Excel but not in POI

I am trying to open a workbook that I believe is in XLSX format from an older
version of Excel. I'm not entirely sure of the file format, because the file
was downloaded from http://members.fhlbdm.com/member-tools/advance-rates/csv/
which is a banking website not under my control. I am able to open the file
directly in Excel, but not in POI. Here's the stack trace I'm getting when I
try to create a new XSSF workbook using an input stream of the file:

java.lang.NullPointerException
    at
org.apache.poi.xssf.usermodel.XSSFWorkbook.onDocumentRead(XSSFWorkbook.java:284)
    at org.apache.poi.POIXMLDocument.load(POIXMLDocument.java:159)
    at org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:221)
    ...

Please find the file attached. I'm running JDK 7 update 51 and this trace was
taken from a JUnit test case executed in IntelliJ IDEA. I'm using POI with the
OOXML module, built using Maven.

I've tried searching the internet for this exception, and I see a few
descriptions of similar behavior but no resolutions. The following external
link may also be related
http://stackoverflow.com/questions/18274995/nullpointerexception-when-trying-to-read-xlsx-file
as it is also a Mac and a similar error. In this tracker, my problem may be
related to ticket 16488, since the spreadsheet does have some cells with Excel
warnings. 

Thanks in advance!

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org
For additional commands, e-mail: dev-h...@poi.apache.org

Reply via email to