Results 1 to 3 of 3
  1. #1
    hollyanneu2 is offline Novice
    Windows XP Access 2003
    Join Date
    Apr 2015
    Posts
    2

    RIGHT most line VBA for Detail_Print

    Since I am not too familiar with Access VBA programming but am learning. I do have one that I need help with. What I need is the RIGHT most line. I have the LEFT and the between lines but not the RIGHT. I cannot change the Integer 1 to "8" because there is a hidden field in there.

    Will you please help me! And even explain what 'left most line Me.Line (0, 0)-Step(0, lHeight), lDarkGray in red means? Like (0,0) and so on?


    Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)


    Dim lDarkGray As Long: lDarkGray = 3355443
    Dim lWidth As Long: lWidth = Me.Width
    Dim lHeight As Long: lHeight = Me.Height
    'left most line
    Me.Line (0, 0)-Step(0, lHeight), lDarkGray
    'the rest of the vertial lines
    Dim i As Integer
    For i = 1 To 7 Step 1
    Me.Line ((Me("txt" & i).Left + Me("txt" & i).Width), 0)-Step(0, lHeight), lDarkGray
    Next i
    'bottom lines
    Me.Line (0, lHeight)-Step(lWidth, 0), lDarkGray
    End Sub

  2. #2
    NTC is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    Nov 2009
    Posts
    2,392
    very very few people these days manipulate printing via code........are you sure you need to really? are you familiar with the page layout properties of the report object?

  3. #3
    hollyanneu2 is offline Novice
    Windows XP Access 2003
    Join Date
    Apr 2015
    Posts
    2
    Unfortunately the company I work for STILL uses 2003 Access and I inherited a database that produces the letters due on May 1st that I got to get done....These were written from previous developers no longer with the company And as far as page layout properties of the report object - I am getting there but still learning.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 03-23-2015, 08:32 AM
  2. Replies: 1
    Last Post: 11-11-2014, 03:54 PM
  3. Replies: 10
    Last Post: 06-10-2014, 09:03 AM
  4. Detail_Print
    By CamtheChamp in forum Reports
    Replies: 3
    Last Post: 07-16-2012, 03:40 PM
  5. Replies: 7
    Last Post: 04-11-2011, 03:58 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums