We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Text position and images display error when stored in html format

Hi Aspose team,

I am using Aspose Word 17.2 to convert a Word file to a HTML file.
As a result, Some text positions are showing errors and some images (like arrows) are not consistent with the original file.

the java code I'm using:

public void html() throws Exception {
long start = System.currentTimeMillis();

createWordLicense("src/test/config/etc/aspose.lic");

Document document = new Document(
"custom/input/docx/HelloKitty-時程.docx");
HtmlSaveOptions op = new HtmlSaveOptions();

op.setExportTextInputFormFieldAsText(false);
op.setExportTocPageNumbers(true);
op.setExportPageSetup(true);
op.setExportDocumentProperties(true);
op.setExportRelativeFontSize(false);
op.setExportHeadersFootersMode(ExportHeadersFootersMode.FIRST_PAGE_HEADER_FOOTER_PER_SECTION);
op.setImagesFolder("custom/output/docx/aspose");
OutputStream out = new FileOutputStream(new File("custom/output/docx/Resume.html"));

document.save(out, op);
}

And I also uploaded the origin Word file and the convert result.
Please help me figure it out what happend, thanks.

Hi Lai,

Thanks for your inquiry.

While using the latest version of Aspose.Words i.e. 17.3.0, we managed to reproduce this issue on our end. We have logged this issue in our bug tracking system. The ID of this issue is WORDSNET-15073. Your thread has also been linked to the appropriate issue and you will be notified as soon as it is resolved. Sorry for the inconvenience.

Best regards,