Topic Options
#24634 - 06/26/09 02:24 PM conditional text with variable data
ourtown Offline
Member

Registered: 10/09/08
Posts: 40
Loc: Tampa, Fl USA
Is there a way for me to set an address block for example on a conditional basis without adjust the variable field for the entire layout? For example this is my address block.
@Endorse@
@Business@
@First@ @Last@
@Address@
@City@, @St@ @Zip@

If the First, Last fields are blank I don't want a blank line in my address block. I would prefer it to display as

@Endorse@
@Business@
@Address@
@City@, @St@ @Zip@

Is there an expression I could create to do this? I have a few different layouts already. I am hoping to avoid duplicating ones I have and complicating my current layout expressions to include those fields being empty skip. I could also apply this to other functions. Thanks for your help.

Top
#24635 - 06/27/09 12:21 AM Re: conditional text with variable data
Sander vd Berg Offline
OL Expert

Registered: 06/10/08
Posts: 201
Loc: Objectif Lune NL
How about replacing @First@ and @Last@ by a new variable with an expression like ..

Code:
TRIM(@First@ & " " & @Last@)
.. so you can use Remove Empty Lines?

And I know this won't help you right now, but this will no longer be necessary in the next version of PSM. It will consider a line to be empty if it only consists of whitespace.

Top