Results 1 to 3 of 3
  1. #1
    4 Star Lounger
    Join Date
    Oct 2003
    Location
    Guelph, Ontario, Canada
    Posts
    428
    Thanks
    0
    Thanked 0 Times in 0 Posts

    pause printing in order to print on reverse of pag

    Using Access 2000

    Below is code behind a report.

    <code>Option Compare Database
    Option Explicit
    Private Printing As Integer

    Private Sub PageHeaderSection_Format(Cancel As Integer, FormatCount As Integer)

    If Me.Page = 1 Then
    Me.Label161.Visible = False
    Else
    Me.Label161.Visible = True
    End If

    End Sub

    Private Sub Report_Activate()

    'Occurs only when previewing
    Printing = -1
    End Sub

    Private Sub Report_Deactivate()
    'Reset for next time
    Printing = 0
    End Sub

    Private Sub Report_Page()

    If Me.Page > 1 And Printing > 0 Then

    Call MsgBox(" Please turn paper over" _
    & vbCrLf & "and press OK to print page 2." _
    , vbExclamation, "Pause printing")
    End If

    End Sub

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

    'Occurs when previewing and when printing
    Printing = Printing + 1
    End Sub</code>

    What is supposed to happen is that page 1 goes to the printer, then the user is prompted to turn the page over and press the OK button to print on the reverse side.

    This worked perfectly on several older inkjet printers, but won't work on new laser printers.

    Any suggestions as to how to change the routine, or an alternative approach?

    Tom

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: pause printing in order to print on reverse of pag

    You could open the report from a form, print page 1, then display a message and finally print page 2:

    Private Sub cmdReport_Click()
    DoCmd.OpenReport "rptCategories", acViewPreview
    DoCmd.PrintOut acPages, 1, 1
    MsgBox "Please turn paper over ... etc."
    DoCmd.PrintOut acPages, 2, 2
    End Sub

  3. #3
    4 Star Lounger
    Join Date
    Oct 2003
    Location
    Guelph, Ontario, Canada
    Posts
    428
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: pause printing in order to print on reverse of

    Hans
    Wonderful. Thanks very much.

    Tom

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •