J
JoJo
Thank you for this service, it sure is a big help!!
I copied some code that was on this site for horizontal lines in a report.
The code works great except the lines are number 1-30. I need the horizontal
lines but without the numbers. I tried changing some of the code but I don't
understand enough to take the part out that numbers the lines. Below is the
code, would someone please help me understand what to take out to change the
code to make un-numbered lines? THANK YOU TONS!!!!!
Private Sub Report_Page()
Dim intNumLines As Integer
Dim intLineNumb As Integer
Dim intDetailHeight As Integer
Dim intPageHeadHeight As Integer
On Error GoTo Report_Page_Error
intNumLines=30
intDetailHeight=Me.Section(acDetail).Height
intPageHeadHeight=Me.Section(3).Height
For intLineNum =1 To intNumLines
Me.CurrentY = (intLineNum-1) * intDetailHeight + intPageHeadHeight
Me.Cuttentx = 0
Me.FontBold = True
Me.FontSize=14
Me.Print intLineNum 'print the line number
Me.Line(0,intPageHeadHeight + intLineNum * intDetailHeight) - _
Step(Me.Width,0)
Next
On Error GoTo 0
Exit Sub
Report_Page_Error:
Select Case Err
Case 2462 'no page header
intPageHeadHeight=0
Resume Next
End Select
MsgBox "Error" & Err.Number & "("& Err.Description &_
") in procedure Report_Page of VBA Document Report_Report1"
End Sub
MADBLover
I copied some code that was on this site for horizontal lines in a report.
The code works great except the lines are number 1-30. I need the horizontal
lines but without the numbers. I tried changing some of the code but I don't
understand enough to take the part out that numbers the lines. Below is the
code, would someone please help me understand what to take out to change the
code to make un-numbered lines? THANK YOU TONS!!!!!
Private Sub Report_Page()
Dim intNumLines As Integer
Dim intLineNumb As Integer
Dim intDetailHeight As Integer
Dim intPageHeadHeight As Integer
On Error GoTo Report_Page_Error
intNumLines=30
intDetailHeight=Me.Section(acDetail).Height
intPageHeadHeight=Me.Section(3).Height
For intLineNum =1 To intNumLines
Me.CurrentY = (intLineNum-1) * intDetailHeight + intPageHeadHeight
Me.Cuttentx = 0
Me.FontBold = True
Me.FontSize=14
Me.Print intLineNum 'print the line number
Me.Line(0,intPageHeadHeight + intLineNum * intDetailHeight) - _
Step(Me.Width,0)
Next
On Error GoTo 0
Exit Sub
Report_Page_Error:
Select Case Err
Case 2462 'no page header
intPageHeadHeight=0
Resume Next
End Select
MsgBox "Error" & Err.Number & "("& Err.Description &_
") in procedure Report_Page of VBA Document Report_Report1"
End Sub
MADBLover