Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

adding empty rows 1

Status
Not open for further replies.

jailerg013

Technical User
Nov 19, 2003
16
US
I have a report in Access that has been formatted to display borders around each record so that it appears as a table and that table has got to have a certain number of rows per page. my problem is I need the last page to continue with the table rows to the page footer even if there are not enough records. Does anyone know how I can do this.
 
I would remove all line controls and then use the Line method in the On Page event of the report. You may need to change some numbers to meet your needs.
Code:
Private Sub Report_Page()
    Dim intRows As Integer
    Dim intLoop As Integer
    Dim intTopMargin As Integer
    intRows = 24
    intDetailHeight = Me.Section(0).Height
    intTopMargin = 360
    For intLoop = 0 To intRows
        Me.Line (0, intLoop * intDetailHeight + intTopMargin)- _
            Step(Me.Width, intDetailHeight), , B
    Next
End Sub

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
You are awesome. One more little thing I don't need the lines in my header how could I remove them. Thank you for your help.
 
You would set the value of intTopMargin to a higher number.

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
I tried that, but it just keeps moving my page header down with the lines.
 
The code that I provided won't move anything anywhere. It will only draw lines/boxes. I don't know what would cause your page header to move down.

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
OK, I'll keep working on it. I'm sure its a simple problem I'll just have to figure it out.Thanks for all your help.[2thumbsup]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top