Option Compare Database
Dim row As Long
Dim RowsInPage As Integer
Private mySum As Double
Private Sub 报表页脚_Print(Cancel As Integer, PrintCount As Integer)
Me.本页小计2 = mySum
End Sub
Private Sub 页面页脚_Print(Cancel As Integer, PrintCount As Integer)
If [Page] <> [Pages] Then
Me.本页小计 = mySum
Else
Me.本页小计标签.Visible = False
Me.本页小计.Visible = False
End If
End Sub
Private Sub 页面页眉_Print(Cancel As Integer, PrintCount As Integer)
mySum = 0
End Sub
Private Sub 主体_Print(Cancel As Integer, PrintCount As Integer)
mySum = mySum + [入库金额]
RowsInPage = 12
row = row + 1
If row >= RowsInPage Then
Me.PageBreak.Visible = True
row = -1
Else
Me.PageBreak.Visible = False
End If
End Sub