Now I am trying to converting doc file into docx file using Doc.java but it gives the following exception..
##SummaryInformation
##DocumentSummaryInformation
##WordDocument
##CompObj
##ObjectPool
##1Table
Exception in thread "main" java.io.IOException: block 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.RawDataBlockList.remove(RawDataBlockList.java:32)
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.storage.RawDataBlockList.fetchBlocks(RawDataBlockList.java:32)
at org.apache.poi.poifs.filesystem.POIFSFileSystem.processProperties(POIFSFileSystem.java:542)
at org.apache.poi.poifs.filesystem.POIFSFileSystem.<init>(POIFSFileSystem.java:176)
at org.apache.poi.hwpf.HWPFDocument.verifyAndBuildPOIFS(HWPFDocument.java:133)
at org.apache.poi.hwpf.HWPFDocument.<init>(HWPFDocument.java:146)
at org.docx4j.convert.in.Doc.convert(Doc.java:58)
at org.docx4j.convert.in.Doc.main(Doc.java:396)
I think this line gives error
HWPFDocument ...