?
Solved

MS Access conditionally print a group footer

Posted on 2011-02-16
3
Medium Priority
?
503 Views
Last Modified: 2012-05-11
In an Access report I need to print a group footer if the date range is more than 1 day. If not I need to suppress the group footer altogether. I have code in the in the On Format property of the group footer where I compare the dates. This appears to work but I do not know the code to suppress the group footer. Your assistance is appreciated. Thanks.
0
Comment
Question by:StampIT
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
RgGray3 earned 1000 total points
ID: 34909392
If you have the logic worked out to decide to cancel the printing of the section

use the Cancel property of the section

Private Sub GroupFooter0_Print(Cancel As Integer, PrintCount As Integer)

    If...  your logic
         Cancel = True
    End if


From microsofts help
"The Print event occurs after data in a report section is formatted for printing, but before the section is printed. "

0
 

Author Closing Comment

by:StampIT
ID: 34917120
Thanks for the help
0
 
LVL 11

Expert Comment

by:RgGray3
ID: 34918102
Glad to help...
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access custom database properties are useful for storing miscellaneous bits of information in a format that persists through database closing and reopening.  This article shows how to create and use them.
Did you know that more than 4 billion data records have been recorded as lost or stolen since 2013? It was a staggering number brought to our attention during last week’s ManageEngine webinar, where attendees received a comprehensive look at the ma…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question