Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.pagelayout
Chuck Chuck is offline
external usenet poster
 
Posts: 1
Default Microsoft Word Document Merging

I have existing documentation, an Instructor Guide and a Participant Guide.
I need to merge them in by some automated means so the pages align
numerically. Page one of the Instructor guide as the first page, page one of
the participant guide as the second page so when I print the document out and
put it in a binder, the pages are facing each other.

Can this be done? If so, how?
Thanks!!!!!
--
Chuck

  #2   Report Post  
Posted to microsoft.public.word.pagelayout
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Microsoft Word Document Merging

Here is the code for a macro that I created for someone who wanted to
compile a document with alternating pages coming from different source
documents.

Dim sourcea As Document, sourceb As Document, target As Document
Dim Pages As Integer, Counter As Integer
Dim targetrange As Range

Set sourcea = Documents.Open(FileName:="...")
sourcea.Repaginate
Pages = ActiveDocument.BuiltInDocumentProperties(wdPropert yPages)
Set sourceb = Documents.Open(FileName:="...")
Set target = Documents.Add
target.PageSetup.LeftMargin = sourcea.PageSetup.LeftMargin
target.PageSetup.RightMargin = sourcea.PageSetup.RightMargin
target.PageSetup.TopMargin = sourcea.PageSetup.TopMargin
target.PageSetup.BottomMargin = sourcea.PageSetup.BottomMargin
target.AcceptAllRevisions
Counter = 0
While Counter Pages
sourcea.Activate
ActiveDocument.Bookmarks("\page").Range.Copy
Set targetrange = target.Range
targetrange.Start = targetrange.End
targetrange.Paste
ActiveDocument.Bookmarks("\page").Range.Cut
sourceb.Activate
ActiveDocument.Bookmarks("\page").Range.Copy
Set targetrange = target.Range
targetrange.Start = targetrange.End
targetrange.Paste
ActiveDocument.Bookmarks("\page").Range.Cut
Counter = Counter + 1
Wend
sourcea.Close wdDoNotSaveChanges
sourceb.Close wdDoNotSaveChanges

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Chuck" (DONOTSPAM) wrote in message
...
I have existing documentation, an Instructor Guide and a Participant Guide.
I need to merge them in by some automated means so the pages align
numerically. Page one of the Instructor guide as the first page, page one
of
the participant guide as the second page so when I print the document out
and
put it in a binder, the pages are facing each other.

Can this be done? If so, how?
Thanks!!!!!
--
Chuck



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Word 97 in Windows XP to maintain formatting Charlie''s Word VBA questions Microsoft Word Help 22 May 20th 23 08:51 PM
take yet another lesson from wordperfect "reveal codes" wordperfect is superior Microsoft Word Help 5 May 11th 09 07:58 PM
Word & WordPerfect MrsMac Microsoft Word Help 5 June 10th 06 03:14 AM
Is there something like wordperfect "variables" in microsoft word? Alebenco Microsoft Word Help 2 June 6th 06 04:18 PM
WP merge file to Word sstires Tables 4 February 14th 06 06:26 PM


All times are GMT +1. The time now is 04:08 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"