How to Prevent Table Rows from Splitting Across PDF Pages?

Stimulsoft Reports.PHP discussion
Post Reply
felixandrea
Posts: 2
Joined: Tue Jul 30, 2024 8:54 am

How to Prevent Table Rows from Splitting Across PDF Pages?

Post by felixandrea »

Hi everyone,

I'm new to the Stimulsoft community and currently learning how to create reports. I'm having trouble with table rows when exporting a report to PDF. Some rows split between two pages, which makes the report difficult to read.

Is there a way to keep each row together on the same page, automatically moving it to the next page when there isn't enough space? I'd appreciate any advice or examples of the settings I should use.

Thanks in advance for your help!
Lech Kulikowski
Posts: 7886
Joined: Tue Mar 20, 2018 5:34 am

Re: How to Prevent Table Rows from Splitting Across PDF Pages?

Post by Lech Kulikowski »

Hi,

Yes, this is controlled by the CanBreak property of the components in the row.

Select the DataBand and set CanBreak = False.
If your text boxes use CanGrow = True (row height depends on the content), keep it. CanGrow together with CanBreak = False gives you rows that stay whole.

Related options that you may want:
KeepDetails/KeepTogether on bands keep a master row together with its detail rows or a header with its first rows.
KeepHeaderTogether and KeepFooterTogether on the DataBand keep the header and footer with the data.
PrintOnAllPages on the header band repeats the header on each new page.

Thank you.
Post Reply