Access 2007 report preventing orphaned lines on an otherwise blank page

DaveRoehrman
DaveRoehrman used Ask the Experts™
on
Some of my reports end with a single line on the last page.  Is there a way to create a conditional page break to prevent this?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Right-click on any section header bar and choose Properties.
You have KeepTogether and Force New Page properties avaialable.

Author

Commented:
I use Keep Together and Force New Page, but...

...If my report footer has just one line, therefore appears alone on the last page, is there a way to include one of the items in the list on the previous page?

In other words, can I in some way state, "Do not allow a single line to be printed on the last (or any) page."?
I dare say you could do it by counting the number of lines already printed on the page, and knowing how many lines fittted onto a page and how many lines (records) there were left to print.





11/26 Forrester Webinar: Savings for Enterprise

How can your organization benefit from savings just by replacing your legacy backup solutions with Acronis' #CyberProtection? Join Forrester's Joe Branca and Ryan Davis from Acronis live as they explain how you can too.

MIS Liason
Most Valuable Expert 2012
Commented:
This is a function of setting the Page break after each section.
This will typically create one last page with just the Report Footer data.

The simple way out may be to delete the Report Footer.
Then put whatever data (Summary) you need in the Group Footer, buy using a Running Sum Textbox.
The use code to only turn on (make visible) this textbox when you are on the last page.

Here is a sample
Access-EEQ-24584056-ReportPageBr.mdb
Jeffrey CoachmanMIS Liason
Most Valuable Expert 2012

Commented:
But again, you may need to provide a bit more info as to the exact structure of your report...
Jeffrey CoachmanMIS Liason
Most Valuable Expert 2012

Commented:
You're Welcome

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial