define area by page break

define area by page break

Forum member · Jul 22, 2015
I am looking for a way to break the converted pages on a page break. Is it possible?

Re: define area by page break

Support · Jul 22, 2015
Hello, The DynamicPDF Converter for .NET library does not have the capability to directly insert a page break at any desired location. However, if you are converting HTML to PDF and have complete control over the HTML being converted, you could insert page breaks in the HTML itself that will cause the page break in the resulting PDF. string htmlString = @"<html><head> </head><body> <p style=""page-break-after:always;"">Paragraph before page break</p> <p>paragraph after page break</p> </body></html>"; Converter.ConvertHtmlString(htmlString, "test.pdf"); Thanks, ceTe Software Support Team.

Re: define area by page break

Forum member · Jul 22, 2015
I am actually trying to break on Microsoft.VisualBasic.Constants.vbFormFeed... from a dat file converting to a pdf. Any suggestions here?

Re: define area by page break

Support · Jul 23, 2015
Hello, It is not possible to set page breaks for any other file types. The above suggested workaround is only possible for HTML to PDF conversions. Thanks, ceTe Software Support Team.

Re: define area by page break

Forum member · Jul 23, 2015
I ended up looping through the file and creating a page at a time. This was beneficial because some files had varied lengths for each section and I was able to keep them to a page. I hope it does not cause problems if they end up printing it.

Re: define area by page break

Forum member · Jun 8, 2016
Hi Does DynamicPDF support any of the other page-break css properties when converting html? for example: page-break-before: always; page-break-after: avoid; Does it support the widows and orphans css? Does the page-break style need to be inline? Dallas

Re: define area by page break

Support · Jun 9, 2016
Hello Dallas, In order to convert HTML to PDF, the DynamicPDF Converter requires Internet Explorer. Here is the documentation link that lists out all the requirements. DynamicPDF Converter uses IE to render the HTML and then uses that HTML rendering to create a PDF document. Please make sure that the css tags that you want to use are supported in version of IE that is installed on the machine where the Converter is running. Thanks, ceTe Software Support Team.