poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bruce Houghton" <bhou...@globalserve.net>
Subject ExceptionInInitializerError
Date Thu, 06 Jan 2005 14:03:13 GMT
To all;
I get ExceptionInInitializerError at  HSSFWorkbook.
I'm using poi...20040804.jar, and JRE1.4.2_04.
The URL generated "HTTP://www....../.../barry/images/excel.xls"
is correct. Printing the header field shows "HTTP 1.1 200 ok",
more messages, then "application/msexcel", date twice
then the length of the file. Everything I read points to
a compatibility issue.
Any thoughts.
Bruce Houghton 


  HSSFWorkbook Read1() throws IOException {
    URL url = new URL(codeBase, "barry/Images/Excel.xls");
    URLConnection uc = url.openConnection();
    String field = uc.getHeaderField(0);
    for (int i=0;field != null; i++) {
      JOptionPane.showMessageDialog(null, field);
      field = uc.getHeaderField(i);
    }
  SafePOIStream is = new SafePOIStream(uc.getInputStream());
  HSSFWorkbook wb = new HSSFWorkbook(is);
  return wb;
}
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message