Results 1 to 5 of 5
  1. #1
    New Lounger
    Join Date
    Sep 2001
    Location
    Minneapolis, Minnesota, USA
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    If statements in merge docs (Word 2000)

    I need to create a mail merge letter that pulls data in from one of two places in an Excel spreadsheet. If the first field is empty, it pulls in the data from a second field. which will always have data.

    I've tried everything I can think of and all that the help file has to offer under "IF...then...else", but I'm getting nowhere. Is there a trick to this?

    Thanks in advance for your assistance!
    <img src=/S/grin.gif border=0 alt=grin width=15 height=15>

  2. #2
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    Wetherby, Yorkshire, England
    Posts
    283
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: If statements in merge docs (Word 2000)

    Check this site <A target="_blank" HREF=http://www.mvps.org/word/FAQs/index6.html>http://www.mvps.org/word/FAQs/index6.html</A>
    I think you'll find your answer.
    Peter Herworth

    GeoffW - hyperlinks added

  3. #3
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Location
    Sun Prairie, Wisconsin, Wisconsin, USA
    Posts
    2,048
    Thanks
    124
    Thanked 119 Times in 116 Posts
    Charles Kyle Kenyon
    Madison, Wisconsin

  4. #4
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Dublin, Ireland, Republic of
    Posts
    2,697
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: If statements in merge docs (Word 2000)

    You could always create an additional field in th Excel file, which holds the first value where available or the second if the first is blank. If your two existing fields are in A1 and B1 you could have the following formula in C1 :

    IF(A1="",B1,A1). You could then use column C as the merge field, which should have the correct value in all cases.

    Andrew C

  5. #5
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Los Angeles Area, California, USA
    Posts
    7,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: If statements in merge docs (Word 2000)

    { IF { MERGEFIELD FieldOne } = "" "{ MERGEFIELD FieldTwo }" "{ Mergefield FieldOne }" }
    where curly brackets are inserted with Ctrl+F9. This says if mergefield one is blank, use field2, else use field1.

    Just remember that the field in Excel must actually be empty.

    Hope this helps.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •