Results 1 to 4 of 4
  1. #1
    New Lounger
    Join Date
    Oct 2013
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    macros for page numbering in word 2010

    I am trying to write a macro that will move my cursor to the footer, centered, enter page numbers and set for a different first page. Any suggestions?

  2. #2
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Location
    Sun Prairie, Wisconsin, Wisconsin, USA
    Posts
    2,049
    Thanks
    124
    Thanked 119 Times in 116 Posts
    I would suggest preparing a template that already has this footer set up.
    In Word 2007 and later, you can use an alignment tab that is centered between your margins, rather than having a center tab on your ruler.

    http://www.addbalance.com/usersguide/templates.htm
    http://www.addbalance.com/usersguide...rait&Landscape

    Keep in mind if you try to do this with a macro that each document can have many sections; each section can have up to three different footers. The footers in different sections may or may not be linked to previous. Any macro has to address all possibilities.

    http://www.addbalance.com/usersguide/sections2007.htm
    Last edited by Charles Kenyon; 2013-10-31 at 08:28.
    Charles Kyle Kenyon
    Madison, Wisconsin

  3. #3
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,055
    Thanks
    2
    Thanked 417 Times in 346 Posts
    Quote Originally Posted by Charles Kenyon View Post
    each section can have up to three different footers. The footers in different sections may or may not be linked to previous
    Actually, every Section always has three headers and three footers; the only issue is whether the page layout is configured to display them. If not taken into account, this can produce unexpected results if two Sections having, say, a different odd and even layout are separated by a Section that has, say, a different first page layout and the 'same as previous' attribute for any of the headers/footers spans the latter two Sections.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

  4. #4
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Location
    Sun Prairie, Wisconsin, Wisconsin, USA
    Posts
    2,049
    Thanks
    124
    Thanked 119 Times in 116 Posts
    What both Paul and I are telling you is that such a macro is not a trivial project and requires a thorough understanding of Word's object model.

    I would also recommend saving your desired footer as a building block. http://www.addbalance.com/usersguide...utocorrect.htm

    You should also know that the automatic page numbers in Word are fields. That is, the PAGE and NUMPAGES fields (with sometimes the SECTIONPAGES field). http://word.mvps.org/FAQs/Numbering/PageNumbering.htm

    That said, why is it that you want it to be a macro? Many people coming from a Word Perfect environment automatically think in terms of macros to create text. Perhaps there is a valid reason to use a macro. It is just that Word provides other tools that may better meet your objectives.
    Charles Kyle Kenyon
    Madison, Wisconsin

Posting Permissions

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