一个通用:报表补线模块
==========
Option Compare Database
Option Explicit
Dim f, i As Long
'借签了 Green Ng 兄的代码
Private Sub Report_Open(Cancel As Integer) '加空行的直线
End Sub
Private Sub ReportFooter_FORMat(Cancel As Integer, FORMatCount As Integer) '加空行的横线
If [Page] = [Pages] Then
f = DCount("*", "computer")
f = 33 - (f Mod 31)
'Me![Linebase].Height = Me![Linebase].Height * f '尾直线高 = LineBase * f
For i = 0 To 5 '加直线从 Line0 到 Line5?
Me("Line" & i).Height = Me("Line" & i).Height * f
Me("Line" & i).Visible = True
Next
For i = 1 To f
Me.Line (Me![Line5].Left, Me.Section(0).Height * i)-(Me![Line0].Left, Me.Section(0).Height * i)
Next