Code to split pages

C

Carrick's Cat

Sorry, couldn't think of a better title!

I finally found out (thanks to the newsgroup here), how to set up a
mail merge to pick and choose different paragraphs (using the AutoText
merge field method).

However, I've run into a small problem: some combinations of
paragraphs are one page long, some two. I need a code for the page
numbers, i.e., page X of Y. I can't have page 1 of 2, for instance, if
it is only 1 page long (client is completely anal aboot these things).

It might just be an Oscar-impaired, Monday morning, snow storm coming
brain lock, but nothing is coming to mind.

Windows 2000, Excel and Word 97 SR-2.

Thanks in advance.

CC
 
G

Graham Mayor

What do you want to display if there's only one page?

{ IF { SECTIONPAGES } <> 1 "Page { PAGE } of { SECTIONPAGES }" }

will only print the page number if there is more than one page

Page { PAGE }{ IF { SECTIONPAGES } <> 1 " of { SECTIONPAGES }" }

will print Page 1 on a one page document and Page x of y on a two or more
page document.


--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP


<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top