Hi Bing, maybe the wmfs are missing the wmf header, which can be chopped off, when the wmf is embedded [2] - so if the size is 22 bytes to big, this would be a good indication.
I've started to implement wmf parsing a while ago and maybe you can recreate the header with the WmfPlaceableHeader class [1]. Andi [1] http://svn.apache.org/repos/asf/poi/branches/wmf_render/src/scratchpad/src/org/apache/poi/hwmf/record/WmfPlaceableHeader.java [2] org.apache.poi.hssf.usermodel.HSSFWorkbook.addPicture() On 28.05.2014 12:29, Bing Ran wrote:
Hi, New to the list but I have pressing need to extract all the embedded equation images from an Word 97 .doc file (not .docx). I know all those images are in WMF format. After I dumped the picture content (from the Picture.getContent()) to a file, I found that the file was not entirely a valid WMF or at least they did not have the correct size information. I'd appreciate it so much if someone can get me started on the right track. Thanks! Bing
--------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
