[prev in list] [next in list] [prev in thread] [next in thread]
List: poi-user
Subject: Does your POIFS have circular or duplicate block references?
From: Sebastien ARBOGAST <sebastien.arbogast () gmail ! com>
Date: 2009-05-27 14:25:07
Message-ID: a753b7f80905270725v1b4c63a6w579a507dfdc596fc () mail ! gmail ! com
[Download RAW message or body]
I'm trying to read an existing Excel file with the following code:
File billFile = new File(bill.getFilePathOnServer());
InputStream inp;
Workbook workbook;
try {
inp = new FileInputStream(billFile);
workbook = WorkbookFactory.create(inp);
} catch (Exception e) {
throw new
CannotReadBillFileException(billFile.getAbsolutePath());
}
The file exists, it can be read, but WorbookFactory throws the following
exception:
java.io.IOException: block[ 44016 ] already removed - does your POIFS have
circular or duplicate block references?
at org.apache.poi.poifs.storage.BlockListImpl.remove(BlockListImpl.java:97)
at
org.apache.poi.poifs.storage.BlockAllocationTableReader.fetchBlocks(BlockAllocationTableReader.java:196)
at
org.apache.poi.poifs.storage.BlockListImpl.fetchBlocks(BlockListImpl.java:132)
at
org.apache.poi.poifs.filesystem.POIFSFileSystem.processProperties(POIFSFileSystem.java:538)
at
org.apache.poi.poifs.filesystem.POIFSFileSystem.<init>(POIFSFileSystem.java:176)
at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:317)
at org.apache.poi.hssf.usermodel.HSSFWorkbook.<init>(HSSFWorkbook.java:298)
at
org.apache.poi.ss.usermodel.WorkbookFactory.create(WorkbookFactory.java:59)
at
com.axen.cirb.billchecker.business.impl.BillCheckerServiceImpl.checkBill(BillCheckerServiceImpl.java:70)
... 39 more
Any idea what's wrong?
Sébastien Arbogast
http://sebastien-arbogast.com
http://mooplan.com
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic