View Single Post
  #3   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Peter Jamieson Peter Jamieson is offline
external usenet poster
 
Posts: 4,582
Default Blank Merge Fields Still Print when told not to.

In Word 2002/2003, you can do the following to get at that option:
a. go into Tools|Customize|Commands, select category All Commands, then
locate MailMergeHelper in the list of commands on theright, and drag it to a
menu/toolbar.
b. When you click on the MailMergehelper button (which is the old WOrd 2000
mail merge "wizard", go into option 3, "Merge..." and you will see the
option you are looking for

QAlternatively, you can set up a macro to do it.

In Word 2002/2003, the option is selected by default for new mail merge main
documents. But this feature works in a way that can seem odd:
a. in Word 2002/2003 (or at least, some revisions), blank lines that result
from fields nested in other fields such as IF or INCLUDETEXT fields are not
suppressed. That's different from Word 97/2000
b. To be suppressed, a line needs to be blank, and it also needs to have an
unnested { MERGEFIELD } field that is blank. For example, a line such as

{ IF "{ MERGEFIELD myfield }" = "" "" "{ MERGEFIELD myfield }" }

will not be suppressed even if myfield is blank.

There are probably other subtleties but that's probably enough for most
users...

Peter Jamieson



"lizz1007" wrote in message
...
I am having the same problem. Where did you select "Don't print blank lines
when data fields are empty"? That may work for me.

Here's what didn't work for me, but might for you:

Use and If...then...Else field that test for data in the field. For the
result of the true condition, have it insert that field and a carriage
return and then the next field; for the result of the negative condition,
have it insert just the next field

{ IF { MERGEFIELD fieldthatmightbeblank } "" "{ MERGEFIELD
fieldthatmightbeblank }[CarriageRetrun]
{ MERGEFIELD nextfield }" "{ MERGEFIELD nextfield }" }

You must use Ctrl+F9 to insert each pair of field delimiters. In place of
[CarriageReturn] press Enter (or Shift+Enter)

Use Alt+F9 to toggle off the display of the field codes.



"JohnH" wrote:

Word/Excel 2000
I have a word merge and an excel datafile. Even though I select don't
print
blank lines when data fields are empty, the blank field still prints..
The
excel file is a simple table of name, titles, addresses. I tried manually
blanking out fields that had data and they also print when I delete the
data.

Thanks
John