IF THEN ELSE

S

swimdad16

Is there a way to insert a field, NOT text but an actual merge field, using
the if-then-else clause?

I have am excel file that I'm merging from that contains fields for first
name (FIRST) and preferred first name (PREF)

If PREF is blank I want to insert FIRST
ELSE (Pref has a value) I want to insert PREF.

Can this be done?
 
D

Doug Robbins - Word MVP

{ IF { MERGEFIELD PREF } = "" { MERGEFIELD FIRST } { MERGEFIELD PREF } }

You must use Ctrl+F9 for each pair of field delimiters { } and you use
Alt+F9 to toggle off their display.

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