+ Reply to Thread
Results 1 to 3 of 3

Print Button to Set Default Printer

  1. #1
    Registered User
    Join Date
    01-08-2009
    Location
    Peoria, Illinois, USA
    MS-Off Ver
    Excel 2003
    Posts
    1

    Print Button to Set Default Printer

    I'm pretty new to excel, but I'm starting to figure it out.

    I'm currently trying to figure out how to change printer properties with a user created print button.

    This is on a form which was created by someone who worked here before I did. Basically, the way the form works is there's an input sheet, and a print form sheet. Whatever is put in on the input sheet gets sent to different locations on the print form so that the input is printed into the correct boxes on a pre-made insurance form.

    Well, there's a big green print button on the input sheet so that when you click it, it prints out the print form sheet. That's all fine and dandy... BUT the girls in the office don't print these forms out on their default printer. They print them out on our big copier/printer. So, every time they open up this .xls I have to click on the print form sheet and change the printer properties so that it prints to the copier/drawer 3. As long as they leave this .xls open all day, it's fine. But, it's kind of becoming a pain to have to go to every computer and change the printer properties and hope they don't forget to leave it open, otherwise I have to do it again.

    I'm trying to find out if I can assign specific printer properties to the big green print button so that I don't have to set this up for them every day. It would make things a heck of a lot easier.

    Is this possible? If so, how do I do it?

    Any help/advice would be VERY MUCH appreciated

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678
    Welcome to the forum.

    You can start by recording a macro that selects the printer you want.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Hello vigil87420,

    Here are 2 methods simple methods you can use to change the default printer. The first is to do it from the Command Line and second is a VBA macro.

    Set Default Printer from Command Line
    1. Click the Start button on the Task Bar.
    2. Click Run...
    3. Change the word printer in line below to the printer you want as the default printer. Do not remove the quotes.

    rundll32 printui.dll,PrintUIEntry /y /n "printer"

    4. Copy this line and paste it into the Open: drop down box.
    5. Click OK

    Set Default Printer Macro
    Please Login or Register  to view this content.
    Adding the Macro
    1. Copy the macro above pressing the keys CTRL+C
    2. Open your workbook
    3. Press the keys ALT+F11 to open the Visual Basic Editor
    4. Press the keys ALT+I to activate the Insert menu
    5. Press M to insert a Standard Module
    6. Paste the code by pressing the keys CTRL+V
    7. Make any custom changes to the macro if needed at this time.
    8. Save the Macro by pressing the keys CTRL+S
    9. Press the keys ALT+Q to exit the Editor, and return to Excel.

    To Run the Macro...
    To run the macro from Excel, open the workbook, and press ALT+F8 to display the Run Macro Dialog. Double Click the macro's name to Run it.

    Sincerely,
    Leith Ross

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1