In the resulting HTML file the collapse switch is missing. Is this feature supported in Aspose Words and how would we enable this?
The corresponding code for the transformation in our application is:
HtmlSaveOptions format =
new HtmlSaveOptions(SaveFormat.HTML);
format.setExportHeadersFootersMode(ExportHeadersFootersMode.NONE);
format.setPrettyFormat(true);
new Document(path).save(folder.getAbsolutePath() + File.separator + "out.html", format);
I added an attachment for the input and output file.
@amoll This is expected behavior. If you convert the document to HTML using MS Word the output will be exactly the same. Collapsing content under heading is MS Word feature, not document feature.
Thank you for the quick answer. Could you please give me a hint to a code snippet on how we could find specific headings in the word document and mark them with custom html css properties so that we could implement this ourselves?
It is quite obvious that headings are exported as h1 - h6. But only some of the customer headings have the collapsed property. Can I identify these via the Aspose API and if so: Is there an easy way to mark them in a way that is persisted into the html?
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.