Resuming Printers

Microsoft® Windows® 2000 Scripting Guide

microsoft windows 2000 scripting guide

« Previous | Next »   

After a printer has been paused, it must be resumed. This is because the paused state is a property of the logical printer and is controlled by the print server. You cannot resume a logical printer simply by turning the physical printer on and off.

Instead, printers must be resumed manually by using the Printers control panel or programmatically by using the Resume method of the IADsPrintQueueOperations interface. Until a printer has been resumed, no documents can be printed using that printer. Users will be able to submit print jobs, but those jobs will remain in the queue until the printer has been resumed.

Scripting Steps

Listing 13.12 contains a script that resumes a printer. To carry out this task, the script must perform the following steps:

  1. Use a GetObject call to bind to the printer ArtDepartmentPrinter on the print server atl-ps-01.
  2. Use the resume method to resume printing.

Listing 13.12   Resuming a Printer

1 2 
Set objPrinter = GetObject("WinNT://atl-ps-01/ArtDepartmentPrinter") objPrinter.Resume

send us your feedback Send us your feedback « Previous | Next »   


Microsoft Windows 2000 Scripting Guide(c) Automating System Administration 2003
Microsoft Windows 2000 Scripting Guide(c) Automating System Administration 2003
ISBN: N/A
EAN: N/A
Year: 2004
Pages: 635

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net