List tag for first item does not exported in output HTML using Java

Hi Team,

I am getting incorrect output while extracting html from Rich text SDT. The ‘List label’ information is not present in the first sdt , but is present in other sdt. I want ‘list label’ info to be available in html of first sdt also.

My code :

       HtmlSaveOptions opts = new HtmlSaveOptions(SaveFormat.HTML);
        opts.setPrettyFormat(true);
        opts.setExportListLabels(ExportListLabels.BY_HTML_TAGS);
        std.toString(opts);

Attaching zip containing document and output.

html_extraction_issue.zip (12.7 KB)

Your help will greatly be appreciated. Thanks

@saurabh.arora

The list label is present in the shared output HTML. Could you please share the screenshot of problematic section of output document?

Please create a standalone console application ( source code without compilation errors ) that helps us to reproduce your problem on our end and attach it here for testing.

Thanks Tahir for the reply.

If you will see in the output the

    tag is not coming for first sdt (first paragraph). This is my issue.

@saurabh.arora

We have tested the scenario using the following code example and managed to reproduce the same issue at our side. We have logged this issue as WORDSNET-20953 in our issue tracking system. We will inform you via this forum thread once this issue is resolved.

We apologize for your inconvenience.

Document doc = new Document(MyDir + "sample.docx");
HtmlSaveOptions opts = new HtmlSaveOptions(SaveFormat.HTML);
opts.setPrettyFormat(true);
opts.setExportListLabels(ExportListLabels.BY_HTML_TAGS);

doc.save(MyDir + "output.html", opts);