Delay Print

G

Guest

This is probably simple, but here goes;

I want to delay a print job until sometime in the middle of the night. The
document I want to print is a Word doc, and the printer is a network shared
printer, not a locally connected printer.
 
J

Jay Freedman

Nathan said:
This is probably simple, but here goes;

I want to delay a print job until sometime in the middle of the
night. The document I want to print is a Word doc, and the printer
is a network shared printer, not a locally connected printer.

One way is to use a pair of macros like these. The first one schedules the
running of the second one. Put both macros in Normal.dot, in a module named
Module1 (the default name for a module added by clicking Insert > Module in
the macro editor). Change the time in the When parameter as needed -- you
can also use 24-hour notation, such as "23:30:00".

Sub PrintLater()
Application.OnTime _
When:="11:30:00 pm", _
Name:="Normal.Module1.PrintNow", _
Tolerance:=0
End Sub

Sub PrintNow()
ActiveDocument.PrintOut Background:=False
MsgBox ActiveDocument.Name & " printed at " & Now
End Sub

Open the document you want to print, run the PrintLater macro, and leave
Word running. When you come back in the morning you should find the document
on the printer and the message box on the screen.

Another way would be to create a batch file that contains a command line to
print the document:

start winword.exe "c:\docs\mydoc.doc" /mFilePrintDefault

Then create a scheduled task to run the batch file at the desired time. How
you do this depends on your version of Windows; in WinXP it's Start >
Settings > Control Panel > Scheduled Tasks > Add Scheduled Task.

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.
 

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