Please Note: This article is written for users of the following Microsoft Excel versions: 97, 2000, 2002, and 2003. If you are using a later version (Excel 2007 or later), this tip may not work for you. For a version of this tip written specifically for later versions of Excel, click here: Working with Multiple Printers.

Working With Multiple Printers

Written by Allen Wyatt (last updated July 18, 2022)
This tip applies to Excel 97, 2000, 2002, and 2003


3

You already know that Windows supports multiple printers. Using Excel with multiple printers can be a bother, however, since you must display the Print dialog box, change the printer, and then print the worksheet.

There is a way, however, that you can have one-click printing of your worksheets on a designated printer. To do this, simply create a macro that changes the printer and then prints the worksheets, as shown here:

Sub GoodPrinter()
    Application.ActivePrinter = "HP LaserJet"
    ActiveWindow.SelectedSheets.PrintOut Copies:=1
End Sub

When you create this macro on your system, make sure you change the printer name in the second line of the macro. It must exactly match the name of a printer on your system. (In this example the printer name is set to "HP LaserJet". You should change it to match the name of the printer you want used.)

The trick is to create one of these macros for each of the printers you use. You can then modify a toolbar so that each printer has its own print button. When you then click on the command or button, the appropriate macro is run and you get output on the desired printer.

Note:

If you would like to know how to use the macros described on this page (or on any other page on the ExcelTips sites), I've prepared a special page that includes helpful information. Click here to open that special page in a new browser tab.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (2217) applies to Microsoft Excel 97, 2000, 2002, and 2003. You can find a version of this tip for the ribbon interface of Excel (Excel 2007 and later) here: Working with Multiple Printers.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Cropping Graphics

Excel makes it easy to place a graphic in a worksheet. Once there, you may want to chop off a side (or two) of the ...

Discover More

Breaking a Document Link

Word allows you to link external information into your documents. If you no longer need to maintain the active link, you ...

Discover More

Decreasing Space between Body Text and Footer Text

Figuring out how you want the text in your document to appear on the printed page can sometimes be a bit perplexing. Word ...

Discover More

Professional Development Guidance! Four world-class developers offer start-to-finish guidance for building powerful, robust, and secure applications with Excel. The authors show how to consistently make the right design decisions and make the most of Excel's powerful features. Check out Professional Excel Development today!

More ExcelTips (menu)

Printing More Than One Copy

Need to print more than a single copy of a worksheet? You can do it easily by using the controls in the Print dialog box.

Discover More

Printing Only Non-Blank Worksheets

If you have a workbook containing many worksheets, you might want to print only those worksheets that have some sort of ...

Discover More

Specifying a Paper Tray in a Macro

If you are using a macro to create your printed Excel output, you may need a way to specify that paper should come from a ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is two more than 7?

2019-05-23 10:26:10

Sean Hayes

Hi,

This is probably the solution that I have been looking for.
The problem I have is that my spreadsheet asks the user in a pop up dialogue box how many copies they require. This would make the last line of this obsolete and I'm not sure on how I would incorporate it into the vba I already have.
The code i already have is :-

Sub PrintCurrentSheet(ByVal pFound As Range)
Select Case MsgBox("Print Supply & Fit or Supply Only?" & vbCrLf & "Please select Yes for Supply & Fit, or No for Supply Only", vbYesNo)
Case vbYes
Sheets("Labels").Select
Case vbNo
Sheets("Unbranded Labels").Select
End Select
Range("E1,O1,E22,O22") = pFound
Range("A10,J10,A31,J31") = pFound.Offset(0, IIf(rOnly, -8, -4))
Range("C10,M10,C31,M31") = pFound.Offset(0, IIf(rOnly, -7, -3))
Range("G10,Q10,G31,Q31") = pFound.Offset(0, IIf(rOnly, -6, -2))
Call ToggleOn

'ASKS HOW MANY COPIES TO PRINT
Do
NumberofCopies = Application.InputBox("How many copies do you want to print? Must enter 0-50", Type:=1)
If NumberofCopies = 0 Then ' If user clicks on Cancel button
Call ToggleOff
Exit Sub
End If
If NumberofCopies > 50 Then MsgBox "Max to print is 50 copies" Else Exit Do
Loop
ActiveSheet.PrintOut Copies:=NumberofCopies
Call ToggleOff
Sheets("Scan").Select
End Sub


2018-02-20 02:42:45

Syed M Husain

Sub GoodPrinter()
Application.ActivePrinter = "HP LaserJet"
ActiveWindow.SelectedSheets.PrintOut Copies:=1
End Sub

This macro does not work for excel 2003. It stops at Application.ActivePrinter = "Printer name"


2018-02-02 18:36:26

Mike

I don't know what I'm doing wrong but I tried to ceate a macro using your example and changing out the printer name and when I try to run it nothing happens. No error message but also no output to the printer. Can you give me any ideas what might be wrong with my macro? I am using Excel 2010. The file is stored on a network share but I have both enabled the macros and trusted the document. Thanks.


This Site

Got a version of Excel that uses the menu interface (Excel 97, Excel 2000, Excel 2002, or Excel 2003)? This site is for you! If you use a later version of Excel, visit our ExcelTips site focusing on the ribbon interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.