views:

204

answers:

0

Hello all,

I can't seem to find anyone who has had the same problem as me, which I find hard to believe because it seems like it should be a common need. On to the problem...

I have a pretty standard SSRS 2005 Invoice report that has a header, a few address below the header, a table that contains the line item information about the invoice and a footer.

I have the need to stretch the table to the end of the nearest page. For example, if the table naturally ends in the middle of the second page because that's all the content there is, I need that table to stretch to just above the footer. Likewise, if the table naturally ends four lines after the 8th page, I need the table to stretch to the end of the 8th page and stop just above the footer.

Is there a way for SSRS to do that natively without doing some silly stuff?

So far, I've tried all kinds of crazy stuff including passing all the text of the report line items and determining the printed length of the text, given the font, boldness and font size. This works great at telling me how many printed lines my report line items will take up but now I'm having trouble with the lines that wrap in that the space between the wrapped lines is different than the space between the normal report lines. And even if I am able to set the padding to make the the spacing the same, I run into the problem that if a cell at the end of the page has text that will wrap to the next page, that entire cell moves to the next page, which throws everything else off again.

Bottom line, if anyone has any brilliant ideas on how to reliably stretch a table to the end of the nearest page, I would be forever grateful.

Thanks!!! Jason