|
|
Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
I have been trying to get vertical lines to work in a report using VBA code as suggested by Microsoft here: http://support.microsoft.com/kb/q151543/ (except I replaced Microsoft's default line values with my own):
Private Sub Report_Open(Cancel as Integer) DoCmd.Maximize End Sub Private Sub Report_Close() DoCmd.Restore End Sub
Private Sub Report_Page()
If Me.Page <> 1 then
Me.ScaleMode = 1 Me.ForeColor = 0 ' Repeat the following line of code for each vertical line. ' 1 * 1440 represents 1 inch. ' Draws line at Left Margin. Me.Line (0 * 1440, 0) - (0 * 1440, 14400) ' Draws line at 1 inch. Me.Line (1 * 1440, 0) - (1 * 1440, 14400) ' Draws line at 2 in. Me.Line (1.9 * 1440, 0) - (1.9 * 1440, 14400) ' Draws line at 3 in. Me.Line (5.5 * 1440, 0) - (5.5 * 1440, 14400)
End If
' The 14400 is an arbitrary number to increase the line to the max ' of a section. End Sub Private Sub Detail_Print(Cancel as Integer, PrintCount as Integer) Me.ScaleMode = 1 Me.ForeColor = 0 ' Repeat the following line of code for each vertical line ' 1 * 1440 represents 1 inch. Me.Line (0 * 1440, 0) - (0 * 1440, 14400) Me.Line (1 * 1440, 0) - (1 * 1440, 14400) Me.Line (1.9 * 1440, 0) - (1.9 * 1440, 14400) Me.Line (5.5 * 1440, 0) - (5.5 * 1440, 14400)
' The 14400 is an arbitrary number to increase the line ' to the max of a section. End Sub
The lines show up in the print preview and look great, but they don't print and when I export the report to PDF or Word, the lines dissapear there too. Is there a way to fix this?
|
|
|