Reply
 
Thread Tools Display Modes
  #1   Report Post  
jmh117 jmh117 is offline
Junior Member
 
Posts: 1
Default Blank Line with If...then...else field

Hello,

I'm trying to create a document that will have one address block when the field Agent in my source document is "self" and two address blocks when Agent is not self.

Currently I have the following code for the full address (not using the address block function as I have two addresses in the document and extra text that I want included ("c/o" and "Agent for"):

{IF {MERGEFIELD Agent}= "self" "" "c/o {MERGEFIELD Agent", Agent for Recipient}
{AgentAdd1}
{AgentAdd2}
{AgentCity \f ", "}{AgentState \f " "}{AgentZip}

The merge properly suppresses the line breaks if there is no data in the source document, however, if "self" is in the Agent field in the source document, I get a blank line where the "If...then...else" field is and suppressed lines for the rest of the address block.

For example:

If Ebeneezer Scrooge is Tiny Tim's Agent the following will display:

Tiny Tim's
Address
Block

c/o Ebeneezer Scrooge, Agent for Tiny Tim
One Scrooge Lane
Miser City, Dickens 00000

TEXT OF DOCUMENT

If Tim represents himself (and I need some notation that they are self represented), the following will display

Tiny Tim's
Address
Block



TEXT OF DOCUMENT

Any thoughts on how to fix this problem?
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
How do I avoid a blank line if a mail merge field is empty? Geo 4 Mailmerge 3 April 3rd 12 01:28 PM
using word 2007 suppress blank line when merge field is empty Shelly Mailmerge 1 June 16th 08 08:18 PM
Delete Line if Fill-in field is left blank Cheese_whiz Microsoft Word Help 2 April 1st 08 12:40 AM
line feed when merge field is blank Bev Mailmerge 1 March 22nd 05 09:31 PM
How do I add a space in a line if a merge field is blank? S Cocke Mailmerge 4 February 11th 05 11:13 PM


All times are GMT +1. The time now is 03:05 AM.

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

About Us

"It's about Microsoft Word"