Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / February 2008

Tip: Looking for answers? Try searching our database.

Reset to default printer

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Wes - 28 Feb 2008 15:14 GMT
I have a user that occasionally needs to send a print job somewhere other
than the default printer.  At that point Word remembers his last used printer
but he does not and he ends up "losing" his print jobs by sending them to the
wrong printer.

Is there any way to force Word to always select the default printer when the
Print dialog is open, even if the last print job went to a different printer?

I'm hoping that there is a Print event that can be triggered with every
print request to reset the selected printer to the default.  This would need
to happen whether the Print...(Ctrl+P) command was used or the Print button
on the toolbar was clicked.  Regardless of how, it needs to be pretty much
invisible to the user.

Thanks,
Jean-Guy Marcil - 28 Feb 2008 16:01 GMT
> I have a user that occasionally needs to send a print job somewhere other
> than the default printer.  At that point Word remembers his last used printer
[quoted text clipped - 9 lines]
> on the toolbar was clicked.  Regardless of how, it needs to be pretty much
> invisible to the user.

Normally, you create a Sub called FilePrint that will run whenever users do
CTRL-P or File > Print. In this case, you do not need the sub
FilePrintDefault that runs when users click on the Printer icon on the
standard toolbar. You do not need it becasue if the other sub resets the
printer when it is used, this last sub will always use the correct printer.

This sub will allow users to interact with the print dialog as they wish,
but it will reset the printer to the one that was active when they got to the
dialog.

Sub FilePrint()

Dim strPrinter As String

strPrinter = Application.ActivePrinter

Dialogs(wdDialogFilePrint).Show

With Dialogs(wdDialogFilePrintSetup)
   .Printer = strPrinter
   .DoNotSetAsSysDefault = True
   .Execute
End With

End Sub
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.