I haven’t done a computer related post for awhile so I thought I would write this up so that I can find it the next time I need to do this.
I am setting up a reporting tool to print out inventory counting sheets. We want them to break on a group AND start each group on an odd page number. So being the great googler that I am, of course, I googled. Boy did I ever get a hodge-podge of answers. After trying about 8 of them and having them all mixed together and nothing was working, I decided to do an overall look of what they were doing and start from scratch.
So, here is what worked:
- Create your report, create a sort/group with header & footer displaying.
- In the footer itself –
I put a line of text that says “This page is blank for pagination”
On the Design Tab: Controls -> Insert Page Break
This will appear as a set of small dots – nothing else.
On the Property Sheet:
- Group Header:
FORMAT: Force New Page: Before Section - Group Footer:
FORMAT: Force New Page: Before Section
EVENT: On Format: Event ProcedureHere is the code that I have for that Event Procedure:
Private Sub GroupFooter0_Format(Cancel As Integer, FormatCount As Integer)
Me.GroupFooter0.Visible = ((Me.Page Mod 2) = 0)
End Sub
GroupFooter0 is the name of my group, you will have to change that to what your footer is named.
Goods & Bads:
- Good: you get a blank page so that each group will start on a odd page number – for duplex printing
- Bad: the page header also prints out on that blank page. This was okay with me, so I left it.