Merging data with INSERTTEXT and MERGEFIELDs

J

James

Hi,

I am trying to set up a letter head. This letter head contains text boxes
that arrange the address and salutation details etc. I would like to be able
to merge this letterhead into the Header of my Letter, and then use a
mailmerge to populate the MERGEFIELD data in the textboxes.

I am using an INSERTTEXT to pull in the letterhead to the header of my
letter, but for some reason when I do this Word drops the MERGEFIELDs leaving
ordinary text, thus when the Mailmerge occurs, the header is not populated
with the details, just left with the text used to identify the fields.

What I am hoping to find out is, if I can manage to get the text boxes to
retain there MERGEFIELDs through the INSERTTEXT ? If not is there a way
around it that you know of ? If not then do you know how to reference frames
by name ? i.e so that I can change there values from code like you can with
textboxes.

Sorry for the long post, hope someone is able to help as I am really stuck

Cheers, James
 
D

Doug Robbins - Word MVP

I am not really sure what you are doing, but why don't you start with the
letter head in the mailmerge main document and then just use mergefields in
the normal way to populate the address and salutation details when the
letter is merged.

--
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
 
G

Graham Mayor

While I would agree with Doug on this, I should also point out that as text
boxes are in the graphics layer of the document, the merge will not see the
fields they contain.

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


<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 
J

James

Im afraid that isnt an option for me. The way our letters (and those of our
customers) are set up are in two documents. The main letters and the headers
for the different types of people i.e clients, suppliers etc.

In the Header I have text boxes to arrange the layout. To ensure the
customer can start typing right after the heading I would like to put all the
header information into the letters header. The problem is that when
Inserting text boxes into the header the field {} info is lost and all that
remains is the text <<fieldname>> without the MERGEFIELD info. This only
occurs when merging into the header and I dont know why....

I hope this explains it better, any help would be most appreciated.

James
 
J

James

text boxes are in the graphics layer of the document, the merge will not
see the
fields they contain.

The thing is that it works in the main part of the document, if I include a
link to a document with the text boxes in, then perform a mail merge it
works. It pulls in the text boxes, retains their fields and then merges the
data. It even works in the header if I dont include it from another document.
But when I try to include the text boxes into the header, it drops the fields.
 
P

Peter Jamieson

Some field types will not work, the merge can sometimes be finickity
(complaining about locked fields), and sequencing is a problem if you need
to use { NEXT } fields etc., but Word will merge into merge fields into Text
boxes and even into other inserted objects such as org charts.

Peter Jamieson
 
P

Peter Jamieson

I don't think you're gong to be able to do this - the usual workarounds
(e.g. bookmarking the part you want to include and only including the
bookmarked bit, using a frame instead of a text box) don't work. However, I
can't say I've tried every possibility.

If you only need the address and other merged info. on the first page of the
document, I would probably try the following:
a. Check File|Page Setup|Layout|Headers and Footers|Different First Page
b. also in File|Page Setup, make the top margin as small as possible
c. Includetext your file in the body of the document instead of the header
d. temporarily insert a page break so you can get at the page2
headers/footers, and put paragraph markers or other filler material in there
to pushthe margin down to where you need it.
e. remove the page break.

Peter Jamieson
 
J

James

Hi,

Well, I have taken your advice and abandonned trying to import the text
boxes into the header with mergefields, but instead have put them in the
first line of the main document.

To ensure the letter text remains where it should be, I have grouped the
text boxes and wrapped the top and bottom with a top padding of 5cm and a
bottom of 1cm. This seems to lay it out nicely.

Thanks for your help and knowledge.

Just a quick summary for anyone reading this and wondering:

- Text boxes will loose there mergefields, if included into a header. No way
around it.
- To have a similar effect you can group the boxes at the top of the main
document with wrapping to exclude text
 

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