UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Subreport On Last Page?, Access 2016    
 
   
tbs
post Nov 8 2019, 09:53 AM
Post#1



Posts: 333
Joined: 12-February 13



Hi,

I have a report with several subreports. The last subreport, I want it to be on the last page of the entire report (as if there's a page break).

Is this even possible? I hope this makes sense.

Thanks in advance.
Go to the top of the page
 
LeeAnn
post Nov 8 2019, 10:52 AM
Post#2



Posts: 1,291
Joined: 2-February 00
From: Mississippi USA Central Time Zone


You can try adding a report footer on the report, place the subreport in the report footer and make the report footer property Force New Page to Before Section. let me know if that works for you.

--------------------
Lee Ann Davidson
Go to the top of the page
 
GroverParkGeorge
post Nov 8 2019, 10:56 AM
Post#3


UA Admin
Posts: 36,203
Joined: 20-June 02
From: Newcastle, WA


This is exactly how I'd try to do it as well. Of course, we always appreciate feedback on actual results.

--------------------
My Real Name Is George. Grover Park Consulting is where I did business for 20 years.
How to Ask a Good Question
Beginning SQL Server
Go to the top of the page
 
tbs
post Nov 8 2019, 11:29 AM
Post#4



Posts: 333
Joined: 12-February 13



That is clever! Worked like a charm.

notworthy.gif
Go to the top of the page
 
LeeAnn
post Nov 8 2019, 11:46 AM
Post#5



Posts: 1,291
Joined: 2-February 00
From: Mississippi USA Central Time Zone


Glad to hear it worked. pompom.gif

--------------------
Lee Ann Davidson
Go to the top of the page
 
tbs
post Dec 5 2019, 03:59 PM
Post#6



Posts: 333
Joined: 12-February 13



I need to revisit this subject. As I mentioned earlier, the above recommendations worked for me. However, if the subform has nothing in it, I still get a full page of blank page with the original report header.

What I want to do if there is no record in the subform, thenno report footer (no blank page).

I tried the following workaround but to no avail:

- show page header and page on the subreport: NO
- CAN GROW, CAN SHRINK: YES
- I put ' Cancel = True ' on the subreport NO DATA property

none the above worked. I still get a full blank page with the Master Report's header/footer when the last subreport has no record.
This post has been edited by tbs: Dec 5 2019, 04:06 PM
Go to the top of the page
 
tbs
post Dec 5 2019, 04:11 PM
Post#7



Posts: 333
Joined: 12-February 13



I think I found the answer to my own question:


In the main report property sheet, set the report footer height to 0", and YES to can grow.
Go to the top of the page
 
tbs
post Dec 6 2019, 08:20 AM
Post#8



Posts: 333
Joined: 12-February 13



I spoke too soon. My 'what I thought was a' solution turned out to be not working.

I'm back to my question from yesterday - how do I prevent the page from Forcing a New Page at the Report Footer if there is no record in the subreport?
Go to the top of the page
 
tbs
post Dec 6 2019, 09:25 AM
Post#9



Posts: 333
Joined: 12-February 13



Now i'm 99.9% sure I got it this time.

Report Footer should have subreport. Let's call it srpt1.

Report Footer should have Force New Page - Before Section in the Property Sheet/Format.

Then on the report load property, put in:

If Me.srpt1.Report.HasData Then
Me.ReportFooter.Visible = True
Else
Me.ReportFooter.Visible = False
End If

That did the trick, at least for now.
Go to the top of the page
 


Custom Search


RSSSearch   Top   Lo-Fi    14th December 2019 - 11:43 AM