Thanks, Tony. Maybe I just don't understand how to run it. I'm really not
that great at VBA. I pasted in the code then returned to the document,
pressed F5 to run it and Find and Replace window pops up already on the Go To
tab. It asks me to enter a page number. I had page 1, inserted a page break
to make page two before I ever entered the code. What am I doing wrong?
Also, if this code doesn't work, maybe we can do this another way. I am
going to make a two-page template with each page having a separate layout. I
want the user to be able to add pages to a document based on the template but
they will need to have two pages added each time. For example, page 1 & 2
exists and they need to add another "set" (page 3 & 4 simultaneously). Page
3 & 4 will have the same layouts as page 1 & 2, respectively. Same goes if
they need page 5 & 6 added. Understand? I can't seem to get a good answer
no matter how I pose the question. I'm not giving up. There must be a way!
> Hi aal,
>
[quoted text clipped - 44 lines]
> Next
> End With
Graham Mayor - 27 Mar 2008 14:52 GMT
Press ALT+F8, select the macro and click Run
See http://www.gmayor.com/installing_macro.htm

Signature
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP
My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Thanks, Tony. Maybe I just don't understand how to run it. I'm
> really not that great at VBA. I pasted in the code then returned to
[quoted text clipped - 61 lines]
>> Next
>> End With
Jean-Guy Marcil - 27 Mar 2008 15:58 GMT
> Also, if this code doesn't work, maybe we can do this another way. I am
> going to make a two-page template with each page having a separate layout. I
[quoted text clipped - 4 lines]
> they need page 5 & 6 added. Understand? I can't seem to get a good answer
> no matter how I pose the question. I'm not giving up. There must be a way!
You have to describe this with more details.
When the user adds pages, I understand that he must always add a set of two
pages.
From your description, and from the code I have seen, is it necessary that
the content of the added pages be the same as the content of existing pages?
In other words, if the user adds pages 3 & 4, must the content be the same as
the content from pages 1 & 2? Or just the lay out? What if pages 5 & 6 are
added in a document that contains 10 pages? Should the content of the new
pages 5 & 6 be identical to the content of 2 existing pages (That the user
would choose), or again, should just the layout be forced?
Can pages be added anywhere in teh document? Or just at the end? If
anywhere, since pages are added as a set of 2 pages, can the added pags be
inserted between an odd-numbered page and an even-numbered page (e.g. between
pages 3 and 4); or always between an even-numbered page and an odd-numbered
page, like between pages 4 and 5 or pages 2 and 3?
If you are working with layouts only, the whole copy/paste/InputBox approach
is wrong.
Also, are you working with templates (*.dot) or documents (*.doc)?
What Word version?
Tony Strazzeri - 28 Mar 2008 01:52 GMT
On Mar 28, 1:58 am, Jean-Guy Marcil
<JeanGuyMar...@discussions.microsoft.com> wrote:
> > Also, if this code doesn't work, maybe we can do this another way. I am
> > going to make a two-page template with each page having a separate layout. I
[quoted text clipped - 28 lines]
> Also, are you working with templates (*.dot) or documents (*.doc)?
> What Word version?
Additionally see my response to your other post "Auto Duplicate a Page
in Word?"
Cheers
TonyS.
Tony Strazzeri - 28 Mar 2008 01:24 GMT
> Thanks, Tony. Maybe I just don't understand how to run it. I'm really not
> that great at VBA. I pasted in the code then returned to the document,
[quoted text clipped - 59 lines]
> > Next
> > End With
Put your in the macro in the VBA IDE then Press F5.