Using poi jar 2.5 - java.io.IOException: unable to read entire block.
posted 10 years ago
I am writing a web app using JSPs and I want to use apache hpsf (poi 2.5.1) to read a word document and extract the properties (metadata) of the document. I followed the example code provided in the howto from the apache site - http://poi.apache.org/hpsf/how-to.html - I am having a problem where I get a java.io.IOException: unable to read entire block: 352 bytes read; expected 512 bytes. I tried to use the poi-3.0.jar and I still get the same error. Also, I have searched the internet and I have found similar problems where the persons where attempting to read MS Excel docs using poi hssf and they received the same error. So far I have not seen any viable solutions. Any and all suggestions are welcomed. Thanks.
I know that this post is old but I faced this issue yesterday and was searching for a reply and found this thread. Thought this might be useful for someone who searches for a solution for similar problem in the future.