You seem to be using HSSFWorkbook to read .xlsx files. Use either 
WorkbookFactory or XSSFWorkbook .

http://poi.apache.org/spreadsheet/quick-guide.html#ReadWriteWorkbook

Yegor


Hi i m getting the below exception when i try to .xlsx files. Even though i
tried with POI 3.2 version.

Can you tell me the solution for the problem.

java.io.IOException: Invalid header signature; read 1688935826934608,
expected -2226271756974174256
        at
org.apache.poi.poifs.storage.HeaderBlockReader.<init>(HeaderBlockReader.java:88)
        at
org.apache.poi.poifs.filesystem.POIFSFileSystem.<init>(POIFSFileSystem.java:83)



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to