Reputation: 5085
I have created a report , which do what it is supposed to do (or almost)
One thing that still bugs me is the following
On some pages , I have 4 boxes (see below)
On other pages, I have 5 boxes (see below).
The number of boxes can change depending on unknown variables/factors.
I would like to have 5 boxes in every page. I'm not sure how to do that. I checked on google and all that came up was some trick to have a fixed number of rows, which is not what I'm looking for
http://www.sqlchick.com/entries/2010/9/11/displaying-fixed-number-of-rows-per-ssrs-report-page.html
Thanks for any insights you will be able to provide me , with.
Upvotes: 0
Views: 59
Reputation: 12786
The fixed number of rows solution that you linked to in your question is actually partially what you want. Your "boxes" are presumably repeating based on rows in a dataset, what you are asking to do is ensure that exactly five rows appear on each page. The linked solution uses an extra parent RowGroup to force a page break after n rows, which will ensure there are not more than n rows per page.
However the issue you are seeing is that sometimes there are four rows per page and this will be because the combined content of the rows ("boxes") is larger than a single page and therefore when the report is rendered the rendering engine is forced to split it onto a new page. The only way to avoid this is to either ensure that five rows of content is never larger than a page (e.g. by shrinking fonts or changing layout and/or setting the CanGrow property to False on relevant report items), or by mandating a lower number of rows per page (e.g. 4 or 3) when setting up the parent row group that forces the page breaks.
Upvotes: 1