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

Free Support Forum - aspose.com

Aspose Word for Java- DOCX conversion to HTML showing draft mode as well

When trying to convert DOCX to HTML using ASPOSE.Word for Java, the converted file is also showing draft mode content. How to avoid conversion of draft mode content & convert only the published version of word document?

i am using HtmlSaveOptions it work for me try this

DocumentBuilder builder = new DocumentBuilder(doc);
HtmlSaveOptions options = new HtmlSaveOptions();
options.setExportPageSetup(true);
options.setExportImagesAsBase64(true);
options.setEncoding(java.nio.charset.Charset.forName("UTF-8"));
options.setPrettyFormat(true);
options.setExportPageSetup(true);
// options.setDocumentSplitCriteria(1);
doc.save(serverPath + "\\temp.html", options);

Hi,

Thanks for your inquiry. Could you please ZIP and attach your input Word document and output HTML file showing the undesired behavior here for testing? Please also attach a screenshot highlighting (encircle) the problematic content in HTML that you don’t want to export to HTML here for our reference. We will investigate the issue on our end and provide you more information.

Best regards,