问题
I'm using a table on my report to present the data. Since it was a lot of data and I wanted to print the report on a A4 page, I split each row into 3 different rows.
My problem is when the report goes to the second page, I want it to break before or after the 3 rows.
example:
name age
address
contact
name age
address
contact
name age
address
* page break *
contact
this is what normally happens. I want to ensure that the page break only happens on the lines.
回答1:
There are multiple strategies to follow:
- The KeepTogether is useful in this case
- If you want it to fit on one page only try adjusting page margins, padding, font size, line height to make the report render more compactly
- Another alternative is to create a table group on the person, and from the group properties (edit group) check the page break at end property. this way you can have each group on a separate page
Hope this helps
回答2:
I'm ended up creating a subreport to represent each item.
I looked for the KeepTogether property but that's probably only for reporting services 2008 (I'm using 2005).
回答3:
If you have the table in a subreport, you must also Right Click -> Format Object -> Uncheck Keep object together.
This was the step that did it for me after I unchecked Keep object together on the table and the subreport details.
回答4:
I had the same problem, tried 'Keep together' and it didn't work. After a long time of changing and trying many things the one thing that did the job was reducing the bottom margin of a page.
来源:https://stackoverflow.com/questions/1177005/report-services-controlling-page-breaks-inside-a-table