If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
includetext, link, or something that keeps headers
I'm trying to do a mail merge that occasionally requires the inclusion of
other documents under certain conditions. For instance, when I merge records 1, 2, and 3 into DocA, my code in DocA detects a certain condition in record 2 which requires the inclusion of DocB for that record. My code: {if {MERGEFIELD iCodeFK}="2" {INCLUDETEXT "\\\\webserver\\\c$\\\DocB.doc"}} While this code includes the text of DocB, it doesn't include DocB's headers and footers. Only DocA's headers and footers remain throughout my new document. Any thoughts on how I can get DocB's headers and footers to be included for that document and still retain the headers and footers for the DocA documents? Thanks. |
#2
|
|||
|
|||
includetext, link, or something that keeps headers
I'm trying to do a mail merge that occasionally requires the inclusion of
other documents under certain conditions. For instance, when I merge records 1, 2, and 3 into DocA, my code in DocA detects a certain condition in record 2 which requires the inclusion of DocB for that record. My code: {if {MERGEFIELD iCodeFK}="2" {INCLUDETEXT "\\\\webserver\\\c$\\\DocB.doc"}} While this code includes the text of DocB, it doesn't include DocB's headers and footers. Only DocA's headers and footers remain throughout my new document. Any thoughts on how I can get DocB's headers and footers to be included for that document and still retain the headers and footers for the DocA documents? Headers and Footers are SECTION-specific. That means you need section breaks between the DocB and DocA parts. Furthermore, the sections have to be formatted with "Same as Previous" turned off. This can be a bit tricky, and may require some trial-and-error, but: 1. Insert a section break at the beginning of DocB. 2. Go into the second section's header/footer and turn off "Same As Previous" 3. In DocA, insert a section break and turn off "Same As Previous" in the new section. Insert the IncludeText field just before this. 4. Mark all of it and press Ctrl+F9 to put it into a pair of field brackets. Now turn this into an IF field. Cindy Meister INTER-Solutions, Switzerland http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004) http://www.word.mvps.org This reply is posted in the Newsgroup; please post any follow question or reply in the newsgroup and not by e-mail :-) |
Thread Tools | |
Display Modes | |
|
|