Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Feb 2002
    Thanked 0 Times in 0 Posts

    Auto Macros (2000)

    I remember from previous versions macros that were specifically named (autonew, autoopen, autoprint etc) that peformed certainly commands upon creating, opening, printing etc. Does 2000 still recognise these macro names? I want to have a macro that occurs automatically when the user prints (without clicking or typing anything to run it) that will remove any text highlighting added by the highlighter pen throughout the document.

    Can anyone please help?

    Thanks in advance.

  2. #2
    Super Moderator macropod's Avatar
    Join Date
    May 2002
    Canberra, Australian Capital Territory, Australia
    Thanked 465 Times in 382 Posts

    Re: Auto Macros (2000)

    There's no Autoprint (I don't know that there ever was one), but the others are there. Details available in W2K's VB help file if you search on "auto macros".

    You can also create your own "Print" macro to replace Word's print command, thus allowing you to run your highlight removal code you need first.


    Paul Edstein
    [MS MVP - Word]

  3. #3
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Silicon Valley, USA
    Thanked 94 Times in 90 Posts

    Re: Auto Macros (2000)

    Word has two print commands: FilePrint, which calls up the dialog, and FilePrintDefault, which just prints immediately to the default printer. By creating macros with these names, you can efficiently commandeer the toolbar buttons, the File>Print... menu option, and Ctrl+P. (A few examples of print macros have been posted here over the past year or so.)

    To find the code to set highlighting to none, I suggest recording a macro of selecting the entire document and making that setting. Unfortunately, it is much more work to rummage through all the headers and footers to clear those. Do you think that will be needed? (Several code examples have been posted here in a variety of contexts; hopefully you can find them.)

    Do you have all the information you need to build your solution?

Posting Permissions

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