Is it possible to force the number of rows in the detail section?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a report in which I need to have in every page 8 lines (rows) in the
detail section. This means that if the detail section has only 1 record, in
the report I should have 8 lines. The first with the info of the record and
other seven blank.

Thanks
 
Can you define "other seven blank". I am having trouble picturing what seven
blanks look like since blank generally suggests the presence of nothing.
 
First of all, thanks for your help.

It's exactly that. The report i'm telling you about is like an invoice. All
the fields in the detail section have borders. Therefore, in the situation
described before, it should appear one line with info and seven lines with
nothing.

"Duane Hookom" escreveu:
 
I would print all my basic repeating format lines etc with the report's Line
and Print methods. The following is sample code to print 30 equal sections
on a page.

Private Sub Report_Page()
Dim intNumLines As Integer
Dim intLineNum 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.CurrentX = 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
 
Hi, Duane!

I've tested these code lines you sent and i think that i can work with them.
It needs some adjusting but i believe it's possible.

Thanks again for you help!

Case solved!!!!

"Duane Hookom" escreveu:
 
Back
Top