Force page break if subreport too big

GrandMasterTuck

In need of medication
Local time
Today, 04:32
Joined
May 4, 2013
Messages
129
Hi folks. I have a report that has several subreports on it to display nested records. The report is rptReport, and I have sbrptPeople and sbrptPictures. The sbrptPeople is a continuous report of a list of people that match some search criteria, and sbrptPhotos is much of the same, except it shows photos. I have the photos set to show really big, like page-width-big, and I discovered a problem:

If there are too many records in sbrptPeople (which is positioned above sbrptPhotos on rptReport), it pushes the photos far enough down that the first photo displayed gets cut off halfway through, and then continues on the next page.

So I tried sticking a page-break in between sbrptPeople and sbrptPhotos, and now if my search results don't include any photos, I get a two-page report with a blank second page!

Anyone know how to get Access to move a subreport to a new page if it's overall height is too tall to fit on whatever is left of the current page?? I have no idea what to do to solve this! Thanks everyone!
 
Have you played with the reports detail section?
 

Attachments

  • Prop.gif
    Prop.gif
    70.7 KB · Views: 741
The.... subreport's detail section, or the primary? I just figured out that I can put a page-break control in the detail section of the subreport and that seems to work for me (the photos show on a new page if there isn't room on the first one, and if there are no photos, I only get one page overall, which is what I want)... the only thing is that, if I put a header in the subreport, it always shows on the previous page (the page before the break), no matter where I put the page-break control in relation to it. This is so frustrating!
 
Yeah, your example works for the subreport and where the subreport breaks on pages, but if the subreport itself is positioned on the main report in such a way that part of the subreport control falls to a new page, it still breaks when you print the main report.

For instance, I have a subreport with a large image on it (which is pulled from the database as an attachment and displayed on the report). The subreport is positioned on the main report near the bottom of the first page. There is a few text fields and a memo field on the main report just above the subreport. The issue I'm having is that, when there is too much text on the main report, so much that it pushes the subreport farther down the page, sometimes the image that the subreport is supposed to display shows up at the bottom of the main report's first page with the bottom part cut off and showing up on the second page of the main report. What I want the report to do is, should the subreport fall off the edge of the first page of the main report, to instead display it at the top of the second page whole.

Does that make sense? Sometimes the way I describe things can be confusing... English is, apparently, my third or fourth language... haha
 
Its worth trying the report wizard if you have not done so yet. If the report wizard can get you close, you may be able tweak it slightly to get what you are looking for.
 

Users who are viewing this thread

Back
Top Bottom