Results 1 to 4 of 4
  1. #1
    New Lounger
    Join Date
    Dec 2004
    Posts
    15
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Macro to hide footer?

    Hello Kind People

    I work in an office where we use a lot of Word 2007 templates and the names of the templates are in a footer. I don't want the footer to print once the template has been filled in, so can I get help with creating a macro that will hide or delete the footer before printing? I envision having a macro button on the quick access toolbar that the users can press before they print, but if there is another way, I would appreciate it.

  2. #2
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    Hi chukesgirl,

    No macros required! Simply replace the footer's template name with a field in the footer coded as:
    {IF{PRINTDATE \@ yyyy}= 0 "Template Name"}

    Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste them from this message.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

  3. The Following User Says Thank You to macropod For This Useful Post:

    chukesgirl (2011-05-23)

  4. #3
    New Lounger
    Join Date
    Dec 2004
    Posts
    15
    Thanks
    1
    Thanked 0 Times in 0 Posts

    code hides footer but deletes from original template

    Thank you for this solution Macropod. It does remove the footer when you select print or print preview which is great because I have a significant number of users who can't seem to remember to remove the footer or think it's just too much trouble to open footer and delete! (sorry, for venting) I do want the footer to still appear in the original template. When I opened the template a second time to reuse it, the footer was gone. The reason we need the template names in the original template is because since we have so many of them, when they have to be edited it's good to have the name at the bottom so you know that you are editing the correct one. Is there a solution for this or perhaps I did something wrong?

  5. #4
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    Hi chukesgirl,

    By 'template' do you mean a Word 'dot(x/m)' file, or an ordianry document? Whatever the case, if the file in which the field is placed has ever been printed, the field will no longer display the pre-printing message.

    Using an ordinary document as the 'template' is risky because of the continual exposure to someone printing from that document.

    For a document created from a Word template, though, any prior printing of the template should be inconsequential except, perhaps, that you'd need to do a print preview or something such to trigger an updating of the field.

    Bottom line: use a proper Word template that has never been printed.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

Posting Permissions

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