Hi,
I am using the following method to convert an HTML file to a MS Word document:
builder.InsertHtml(htmlText);
Here is a sample HTML file:
test <p style="page-break-after: always"> test </p><p style="page-break-after: always"> test </p>
When I view the converted MS Word document, the page breaks are missing. If I manually open the HTML file containing the page breaks - using MS Word, the page breaks are present.
Any clues?
Thanks.
Todd
Hi
Thanks for your request. I managed to reproduce the problem on my side. Your request has been linked to the appropriate issue. You will be notified as soon as it is supported.
As a workaround you can try using the following HTML:
var doc = new Document();
var builder = new DocumentBuilder(doc);
builder.InsertHtml(@"<p>test</p>
<br style='page-break-before: always' />
<p>test</p>
<br style='page-break-before: always' />");
doc.Save(@"C:\Temp\out.doc");
Hope this helps.
Best regards,
Hi Todd,
Thanks for your inquiry.
I was able to reproduce the issue on my side. We will inform you when a fix is avaliable. In the mean time please try specifying a page break in HTML like this:
<br style="page-break-before:always; clear:both" />
Thanks,