Results 1 to 3 of 3
  1. #1
    vagetoanima is offline Member
    Join Date
    Mar 2009
    Posts
    6
    Rep Power
    0

    Question HSSFWorkbook Help

    Hello all,

    Currently I am working on a project that requires me to read several Excel Workbooks and I am using the HSSFWorkbook class to do just that. I have a total of 4 work books that need uploading and I have manged to get 3 of the 4 to upload with no problems. Yet the 4th and weirdly enough the most simple/straight forward of the Workbooks is throwing an error when HSSFWorkbook is trying to read it...

    java.io.IOException: Unable to read entire header; -1 bytes read; expected 512 bytes
    at org.apache.poi.poifs.storage.HeaderBlockReader.<in it>(HeaderBlockReader.java:78)
    at org.apache.poi.poifs.filesystem.POIFSFileSystem.<i nit>(POIFSFileSystem.java:83)

    The workbook it's self does not have any special formating, has no macros and only consists of the first worksheet. :confused:

    If any one has any insight into this I would greatly appreciate the help. Thank you.

    Mr. C

  2. #2
    vagetoanima is offline Member
    Join Date
    Mar 2009
    Posts
    6
    Rep Power
    0

    Default A little more

    Hello again,

    Just thought I would elaborate a little more on this. The data that is in the Workbook in question is just String and integer data, that make up dates, locations, dollar amounts. Such as this....

    (empty) | Us Local | Some Random Country | etc. |
    1/1/09 | $123 | $90 | $10 |
    2/1/09 | $125 | $95 | $150 |


    I hope that helps.

    Mr. C

  3. #3
    Join Date
    Jun 2011
    Posts
    4
    Rep Power
    0

    Default

    I have problem read the excel file by hssf which has 30000 rows in it

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •