Results 1 to 3 of 3

Thread: Pause Printing if printer out of paper (error)

  1. #1

    Thread Starter
    New Member
    Join Date
    Aug 2000
    Location
    KL, Malaysia
    Posts
    7
    I created a program to print every html file in a directory to Canon LBP800 printer.
    It can be more than 500 files (pages). Can someone help me to provide codes on how to pause the program if printer is not ready(out of paper etc.). If the program keep printing, and printer is not ready some of the data sent to the printer will be lost.

    Thanks in advance.
    arif

  2. #2

    Thread Starter
    New Member
    Join Date
    Aug 2000
    Location
    KL, Malaysia
    Posts
    7

    please help

    please!!!
    arif

  3. #3
    Guest
    Won't an error come up or something? And it wouldn't print if there were no paper in the printer. Try this though:

    Code:
    Private Sub CMDPrint_Click()
    On Error Goto NP
    Printer.Print data 'whatever you want to print
    Printer.EndDoc
    Exit Sub
    NP:
    Msgbox "An error has occurred while printing!", 16, "Error:  Cancelling Printing..."
    Printer.KillDoc
    End Sub
    That's just a guess.

    For more informaton, look in your Object Browser for Printer.

Posting Permissions

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



Click Here to Expand Forum to Full Width