Close popover
Dan Kirichenko (DanK8687)
Swedbank AB

Swedbank AB
DanK8687 Member since 2019 1 post
Swedbank AB
Posted: March 2, 2020
Last activity: April 6, 2020

Page Breaks in PDF not being applied since Pega 8 Upgrade

We have until recently used Pega 7.2.2, and our application has relied on browser built in PDF generation functionality to comply with business needs, because the HTMLToPDF activity was not satisfactory.

To ensure the generated PDF applied page breaks on predetermined places, we created a section which contained a Dynamic Layout with two content CSS classes.

Within our application skin we added an additional style sheet containing the following css:

@media print{

    page-break-before: always;
    margin: 0;
    padding: 0;
  .ClassName2 {
    page-break-before: always;

Since upgrading to Pega 8 (8.3.1), page breaks have stopped being applied entirely. Our reference 7.2.2 client still applies page breaks as intended.

We have attempted the following solutions:

  • Specifying page-break-before:always, page-break-after:always, position:relative, and combinations of these, in the additional style sheet
  • Adding a container to the section for page breaks. Within that container specifying "page-break-before: always; page-break-after:always" under additional styles.
  • Converting the section for page breaks to non-automated HTML with the code:
<div class="ClassName1 ClassName2"></div>


<div style="page-break-before:always"></div>
  • Removing "@media print{}" from the additional style sheet.

Unfortunately, none of these changes have made any page-breaks appear in the generated PDF.

Any and all suggestions on how to solve this are appreciated. Thank you in advance.

***Edited by Moderator: Pallavi to update platform capability tags***  

Pega Platform 8.3 Enterprise Application Development Dev/Designer Studio User Experience Financial Services Senior System Architect
Moderation Team has archived post,
Close popover This thread is closed to future replies. Content and links will no longer be updated. If you have the same/similar Question, please write a new Question.