Unanswered: Printing Subreports with blank line every 5th.
I am printing a main report in Access 97 (a member sign-in sheet) with two subreports containing member names: one sub with active members and one with inactive members. I have coded each subreport to print a blank line after every 5th line (see code below) , which it does nicely when I preview the subs individually. Both subreports are in the detail section of the main.
When I print the main report, both sub's print fewer than 5 lines, then a blank line, then they work correctly printing a blank line after every 5th.
What am I doing wrong that causes the subs to NOT print in the main report the way they do in the subreports?
The code is from MS Access Support doc Q139046.
Option Compare Database
' This code declares the cLines variable as an integer, and the
' cMaxLine constant as five. You can set the cMaxLine constant
' to insert a blank line after as many lines as you want. For ' example, to add a blank line after every eight lines in the
' report, set cMaxLine=8.
Dim cLines As Integer
Const cMaxLine = 5
Private Sub Report_Open(Cancel As Integer)
' This code initializes the cLines variable to zero.
cLines = 0
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
' This code adds a blank line by setting the NextRecord and
' PrintSection properties.
If cLines Mod (cMaxLine + 1) = 0 Then
Me.NextRecord = False
Me.PrintSection = False