Intentionally put blank rows down the pag

  • Thread starter Thread starter Wally Steadman
  • Start date Start date
W

Wally Steadman

I have built a report and it works great for what it does. But a question
was posed to me about adding blank lines on the page. For example:

If the page for instance can hold 25 rows but the query only results in 5
rows of information, when I print the report it currently only shows the 5
rows that contain data can I have it still fill the empty rows with the same
outlines as the filled rows. So if they print the report in the morning and
throughout the day they get information to add to the report, they don't
have to go to a computer and get in the database, they can just fill in the
blanks with Pen/Pencil and then take the sheet back later to input the data
into access. I know I can export the report to Excel and do what they are
asking, but is there a way to get Access to do it so I don't have to keep
exporting to Excel?
 
You can remove any line controls and replace them with drawn lines from the
On Page event of your report. Here is one sample that you might be able to
modify:

Private Sub Report_Page()
Dim intNumLines As Integer
Dim intLineNumber As Integer
Dim intTopMargin As Integer
Dim ctl As Control
Dim intLineHeight As Integer
Dim intLineLeft As Integer
Dim intLineWidth As Integer
intNumLines = 20
intLineLeft = 720 '1/2 inch from left margin
intLineWidth = 1440 * 5 '5 inches
intTopMargin = Me.Section(3).Height
intLineHeight = Me.Section(0).Height
For intLineNumber = 0 To intNumLines - 1
Me.Line (intLineLeft, intTopMargin + _
(intLineNumber * intLineHeight)) _
-Step(intLineWidth, 0)
Next
End Sub
 
Back
Top