Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Descriptive text under underline to move with underline in mailmerge.

Status
Not open for further replies.

fishmahn

MIS
Feb 23, 2007
39
US
I don't know if this is even possible, but I'm putting merge codes in a Word 2003 document and there's descriptive text under an underline I'm inserting the merge codes for, as well as other merge fields in the same paragraph before the text, which means the underlined area may move, significantly, when mail-merged. Since it's a regulated industry (insurance), I need to keep the form the same, including the descriptive text. So, visually, what I am trying to do is this:

... blah blah blah... the purchaser shall deliver to the escrow account held at ________________________ the sum of ... blah blah blah for a couple more lines ...

Under the underline it needs to say "(name and address blah blah)" and it needs to stay under the underline even though the underlined space may move due to variations from merge fields. In addition, there are merge fields going into the underlined space, which could be quite long. I can do the merge fields, but structuring the description under the underline so it stays there even if the underline moves due to other variables is the issue.

Does that make sense to anyone? Is there a way to do that?

Thx in advance.

Mike.
 


Your ISP must be in IL.

Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 
That's what my IP address shows. And it's right - the main office is in IL.

Mike.
 
This is actually quite easy to do:
1. Delete any existing underlining related to the mergefields.
2. Select the first mergefield to be underlined and press Shift-F9 to expose the field code. It should look something like {MERGEFIELD ClientName} or {MERGEFIELD ClientName \* Mergeformat}.
3. Edtit the mergefield to read {MERGEFIELD ClientName \* Charformat} and underline the 'M' of 'MERGEFIELD'.
4. Press F9 to update the field.
5. Repeat steps 2-4 for each remaining field to be underlined.
6. Underline any required spaces between the mergefields.
7. Run the mailmerge.

Cheers
Paul Edstein
[MS MVP - Word]
 
Macropod, how does that align the description text underneath it?

Mike.
 
Sorry, I mis-read the requirements. The advice I gave relates to keeping the underlining in synch.

What you're asking for (to keep the descriptive text aligned with the movable text above regardless of line-wrapping) really isn't possible in a mailmerge document. This is especially so given that you have no idea in advance whether the mergefield output will be shorter or longer than the descriptive text. Indeed, in any document that's subject to editing you're only going to be able to do that kind of alignment manually.

However, since you're allowed to make some formatting changes, I'd recommend giving serious consideration to breaking the mergefields and descriptive text out into a two-row table, thus:

[blue]Some long, boring, drawn out legal wording, blah blah blah... the purchaser shall deliver to the escrow account held at:
«AccountName» «AccountAddress1», «AccountAddress2».
(name and address of...)
the sum of some dollar amount previously agreed upon by blah blah...[/blue]

If the table and its contents are centred, everything should look fine.

If that's not possible, you may be able to achieve something along the lines of what you've described via the use of ADVANCE fields or an EQ field for inserting the descriptive text. These don't play well with line wraps, however.

Cheers
Paul Edstein
[MS MVP - Word]
 
For an EQ field solution, try something along the lines of:

{EQ \s\up6(\f(«ClientName»,\(name))}{ EQ \s\up6(\f(, and ))}{EQ \s\up6(\f(«ClientAdress1» «ClientAdress2»,address of ...\)))}


or:

{EQ \s\up6(\f(«ClientName» ,\(name and ))}{EQ \s\up6(\f(«ClientAdress1» «ClientAdress2»,address of ...\)))}

The first version uses three EQ fields, with the 'and' in its own field. The second version uses two EQ fields with the 'and' included in the first one. These are to help with line-wrap issues. You could, of course, combine the lot into a single EQ field, which Word will force onto its own line if the text would otherwise wrap.

Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste them from this message. Likewise, you can't type or copy & paste the chevrons (ie '« »') - they're part of the actual mergefields, which you can insert from the mailmerge toolbar.


Cheers
Paul Edstein
[MS MVP - Word]
 
Thanks for the assistance Macropod. I didn't think there was any real way to do that programmatically because of unknown lengths. They'll just have to live with the name/address as the last text of a line, regardless of length, with the descriptive right below it. I showed them what I saw as a worst-case scenario and they said it would do.

I've never looked into EQ fields, I will look into that.

The issue with all the options I've seen so far is that usually the name/address will be pretty long, usually more than 1 line in the contract, causing a wrap. Anyways, I've got it inserted into my program so it can be merged, so it's set the way it is unless something elegant rears its head.

Mike.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top