Can I turn this into a batch file or macro?

G

Guest

I would like to turn the following instructions (for deleting the current
print job) into a batch file, so I don't have to do all this while my laser
is printing up page after page. Is this possible?

To clean out the queue without a reboot:
-Click Start
-Click Run.
-Type cmd
-Click OK.
-A command prompt window will open (looks like a DOS window).
-Type "net stop spooler" (without the quotes).
-Press the Enter key.
-You will see a message after a few seconds that the spooler service stopped
successfully.
-Navigate to and delete all files in the folder
C:\Windows\System32\Spool\Printers. (note that your path, depending on your
XP install, may be C:\WINNT\System32\Spool\Printers). I don't know the path
in Vista, but it's probably the same. These file(s) you're deleting are the
hung print job.
-Type "net start spooler" (without the quotes).
-Press the Enter key.
-After you see a message that the spooler service started successfully, type
"exit" (without the quotes).
-Press the enter key (this is the best way to gracefully close the command
prompt window).
 
G

Guest

I don't reboot when I delete print jobs.

I right-click on the taskbar icon, and work from that.!
 
P

Professor Primo

Paul said:
I would like to turn the following instructions (for deleting the current
print job) into a batch file, so I don't have to do all this while my
laser
is printing up page after page. Is this possible?

To clean out the queue without a reboot:
-Click Start
-Click Run.
-Type cmd
-Click OK.
-A command prompt window will open (looks like a DOS window).
-Type "net stop spooler" (without the quotes).
-Press the Enter key.
-You will see a message after a few seconds that the spooler service
stopped
successfully.
-Navigate to and delete all files in the folder
C:\Windows\System32\Spool\Printers. (note that your path, depending on
your
XP install, may be C:\WINNT\System32\Spool\Printers). I don't know the
path
in Vista, but it's probably the same. These file(s) you're deleting are
the
hung print job.
-Type "net start spooler" (without the quotes).
-Press the Enter key.
-After you see a message that the spooler service started successfully,
type
"exit" (without the quotes).
-Press the enter key (this is the best way to gracefully close the command
prompt window).

Batch file:

net stop spooler
del/f/q "c:\Windows\System32\Spool\Printers\*.*"
net start spooler
 
G

Guest

Thanks, Primo. That did it. I do have a further question. I practiced by
printing a 400 page pdf, and it took roughly 20 pages (after I started the
batch file) before the job itself stopped printing. Would it have stopped
sooner, if the original document was smaller? Or is that simply how long it
takes, regardless, to stop a current print job? Thanks again. This will save
me a fair amount of time when I'm in a big hurry.
 
P

Professor Primo

Paul said:
I practiced by printing a 400 page pdf, and it took roughly
20 pages (after I started the batch file) before the job itself
stopped printing. Would it have stopped sooner, if the original
document was smaller? Or is that simply how long it takes,
regardless, to stop a current print job?

You also have to clear the printer's memory (turn the printer off).
 
G

Guest

OK, thanks. I did find out that the size of the original document didn't
matter--i counted some 24 pages after I cancelled the printing of multiple
copies of an 11-page document.
 

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