How can i make a workbook print to multiple printers

shina67

Board Regular
Joined
Sep 18, 2014
Messages
138
Hi All,

I have a workbook that will automatically print a worksheet within it when certain conditions are met.
The problem I have is that this is a multi-user workbook who work from different pc's.
I want the automatic print to print to the printer that is closest to the users pc.
The workbook is shared via OneDrive.
I have tried the usual method of changing it within the print options for that user.
However, when the workbook automatically saves it also saves the printer options for the rest of the users and sends to the printer that it has been changed to.
I am hoping that one of you helpful bunch can come up with a solution for me with this.
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
How about something like this?
Code:
Dim strRememberDefaultPrinter As String
strRememberDefaultPrinter = Application.ActivePrinter
Application.ActivePrinter = whatever 'set the printer to what you want
'then do your printing
Application.ActivePrinter = strRememberDefaultPrinter
 
Upvote 0
You would need the printer's network name to use in an array or sequence of print commands. And if the printer is on a different server, you would also need the server name to map to the printer.
 
Last edited:
Upvote 0
Use
Application.ActivePrinter
.. although it is not guaranteed to be "closest"
 
Upvote 0

Forum statistics

Threads
1,215,343
Messages
6,124,398
Members
449,155
Latest member
ravioli44

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top