Deleting all jobs in remote print queue

G

Guest

Hello,

We have situations in which we need to delete all print jobs, for remote
print queues, via a script. I tried the 'Net Print /delete' command, but,
I don't see a way to use that without specifying a job number. Does anyone
know of a way to clear out all jobs?

Thanks
M
 
A

Alan Morris [MSFT]

use the prnqctl.vbs script in \windows\system32. This will work if the
remote machine is Server 2003 or XP. If the remote is a cluster you will
need to pick up the Windows Resource kit since WMI interface only works to
the node.


Usage: prnqctl [-zmex?] [-s server][-p printer][-u user name][-w password]

Arguments:
-e - print test page
-m - resume the printer
-p - printer name
-s - server name
-u - user name
-w - password
-x - purge the printer (cancel all jobs)
-z - pause the printer
-? - display command usage

Examples:
prnqctl -e -s server -p printer
prnqctl -m -p printer
prnqctl -x -p printer

--
Alan Morris
Windows Printing Team
Search the Microsoft Knowledge Base here:
http://support.microsoft.com/default.aspx?scid=fh;[ln];kbhowto

This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top