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

Free Support Forum - aspose.com

Converting html to doc style issues

Hi Aspose Team,

We are evaluating aspose.words for java capabilities, during POC we noticed below html code snippet is getting translated in to the word but the sytles are not reflecting in the word doc, in the word document we see Officer/Owner Information but without any background color. We are using document.insertHtml method. Please advise any workaround html code..


Officer/Owner Information

Thanks

Suri.

Hi

Thanks for your request. The problem occurs because you are using DIV. In Ms Word object model there is no analog of DIV so it is translated to simple paragraph. However styles are lost upon such translation. I think in your case, you can simply replace DIV in your HTMl with P tag.

Hope this helps.

Best regards,