sorry for my poor english.
I try to convert a docx file in a html file, but images present in the header section not appear in html. I see html code generated and there is a tag like
- Code: Select all
<img height="20" id="rId1" width="20" />
Java code for export to html is:
- Code: Select all
HtmlSettings hs = new HtmlSettings();
hs.setImageDirPath(pathDirOutput + dirImgsPrefName + fileNoExt + "/");
hs.setImageTargetUri(dirImgsPrefName + fileNoExt + "/");
WordprocessingMLPackage wordMLPackage = WordprocessingMLPackage.load(new File(fileNameWithPath));
HtmlExporterNG2 exporter = new HtmlExporterNG2();
fo = new FileOutputStream(pathDirOutput + fileNameHtml);
javax.xml.transform.stream.StreamResult result = new javax.xml.transform.stream.StreamResult(fo);
exporter.html(wordMLPackage, result, hs);
Please help.
Thanks.
Any help/solution is highly appreciated.