• Change Printer (Word 2000 SP3)

    Author
    Topic
    #391330

    I have a menu button to change printer in certain circumstances ( for a draft print for example). My code is this:
    ActivePrinter “New Name”
    Printout etc
    ActivePrinter “Default Name”

    This works and resets the printer to default where “Default Printer” is the actual name of the dp. What I would like is a wasy of actually saying go back to the default without using its name ie just default. That way if I schange the default printer I don’t have to change the code. I’m sure I’ve seen it somewhere but I’ve searched the references and can’t find it.

    Anyone know if it’s possible and if so how?

    Thanks

    Peter

    Viewing 1 reply thread
    Author
    Replies
    • #698654

      (Edited by jscher2000 on 31-Jul-03 12:09. I remembered there was a typo…)

      Here’s a post from last September that is very step by step. There are weird characters in it that were supposed to be HTML “non-breaking spaces” so if you see those, please ignore them. When the Lounge is fully restored to its new home, you can use this link: post 174601. Until then… please see the attached.

      Added: the line activeprinter.printout should be activedocument.printout (but you’d figure that out eventually smile )

    • #698706

      To answer your question more directly, simply store the name of the ActivePrinter in a string variable:

      dim strPrinterWas as String
      strPrinterWas = ActivePrinter

      ‘ your code to set the new printer and print goes here

      ActivePrinter = strPrinterWas

    Viewing 1 reply thread
    Reply To: Change Printer (Word 2000 SP3)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: