Group:  Microsoft Word ยป microsoft.public.word.mailmerge.fields
Thread: Mail Merge [If...Then...Else...]

Geek News

Mail Merge [If...Then...Else...]
sos-DC 6/8/2007 2:16:01 PM
Under

Tools > Letters > Mail Merge >Insert Word Field (in merge tool bar) is

If...Then...Else...

This window allows for adding text under specific circumstances.

During an online class for Mail Merge, I was shown a similar window, but
instead of inserting text, you would add Mergefields.

The window had the first row (Field name, Comparison, Compare to) or
something similar on the succeeding rows.

I didn't realize I did not know where it is and I would like to find it.

If this makes sense, can anyone tell me how to open this window? I have no
way of reconnecting with the instructor for the online class.

Re: Mail Merge [If...Then...Else...]
"Graham Mayor" <gmayor[ at ]REMOVETHISmvps.org> 6/9/2007 5:30:34 AM
If you are building complex conditional fields, it is better to insert them
manually using CTRL+F9 for each set of field brackets {}. The field dialogs
are too inflexible. See http://www.gmayor.com/formatting_word_fields.htm for
some examples of field construction.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

sos-DC wrote:
[Quoted Text]
> Under
>
> Tools > Letters > Mail Merge >Insert Word Field (in merge tool bar) is
>
> If...Then...Else...
>
> This window allows for adding text under specific circumstances.
>
> During an online class for Mail Merge, I was shown a similar window,
> but instead of inserting text, you would add Mergefields.
>
> The window had the first row (Field name, Comparison, Compare to) or
> something similar on the succeeding rows.
>
> I didn't realize I did not know where it is and I would like to find
> it.
>
> If this makes sense, can anyone tell me how to open this window? I
> have no way of reconnecting with the instructor for the online class.


Re: Mail Merge [If...Then...Else...]
sos-DC 6/11/2007 1:55:02 PM
I previously tried that but could not get it to work.
I did notice that the original field brackets {} hand lines around them but
the ones I entered did NOT. Could that make a difference?

I checked the link you provided but an unable to find anything. I'm not very
good at searching the web.

"Graham Mayor" wrote:

[Quoted Text]
> If you are building complex conditional fields, it is better to insert them
> manually using CTRL+F9 for each set of field brackets {}. The field dialogs
> are too inflexible. See http://www.gmayor.com/formatting_word_fields.htm for
> some examples of field construction.
>
> --
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Graham Mayor - Word MVP
>
> My web site www.gmayor.com
> Word MVP web site http://word.mvps.org
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>
> sos-DC wrote:
> > Under
> >
> > Tools > Letters > Mail Merge >Insert Word Field (in merge tool bar) is
> >
> > If...Then...Else...
> >
> > This window allows for adding text under specific circumstances.
> >
> > During an online class for Mail Merge, I was shown a similar window,
> > but instead of inserting text, you would add Mergefields.
> >
> > The window had the first row (Field name, Comparison, Compare to) or
> > something similar on the succeeding rows.
> >
> > I didn't realize I did not know where it is and I would like to find
> > it.
> >
> > If this makes sense, can anyone tell me how to open this window? I
> > have no way of reconnecting with the instructor for the online class.
>
>
>
Re: Mail Merge [If...Then...Else...]
"Graham Mayor" <gmayor[ at ]REMOVETHISmvps.org> 6/11/2007 2:39:54 PM
The basics of mail merge are covered at
http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
If you tell us exactly what you are trying to achieve, we will tell you what
is possible.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

sos-DC wrote:
[Quoted Text]
> I previously tried that but could not get it to work.
> I did notice that the original field brackets {} hand lines around
> them but the ones I entered did NOT. Could that make a difference?
>
> I checked the link you provided but an unable to find anything. I'm
> not very good at searching the web.
>
> "Graham Mayor" wrote:
>
>> If you are building complex conditional fields, it is better to
>> insert them manually using CTRL+F9 for each set of field brackets
>> {}. The field dialogs are too inflexible. See
>> http://www.gmayor.com/formatting_word_fields.htm for some examples
>> of field construction.
>>
>> --
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> Graham Mayor - Word MVP
>>
>> My web site www.gmayor.com
>> Word MVP web site http://word.mvps.org
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>
>> sos-DC wrote:
>>> Under
>>>
>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool bar)
>>> is
>>>
>>> If...Then...Else...
>>>
>>> This window allows for adding text under specific circumstances.
>>>
>>> During an online class for Mail Merge, I was shown a similar window,
>>> but instead of inserting text, you would add Mergefields.
>>>
>>> The window had the first row (Field name, Comparison, Compare to) or
>>> something similar on the succeeding rows.
>>>
>>> I didn't realize I did not know where it is and I would like to find
>>> it.
>>>
>>> If this makes sense, can anyone tell me how to open this window? I
>>> have no way of reconnecting with the instructor for the online
>>> class.


Re: Mail Merge [If...Then...Else...]
sos-DC 6/11/2007 4:34:10 PM
Thank you.

If this doesn't help, nothing will.

"Graham Mayor" wrote:

[Quoted Text]
> The basics of mail merge are covered at
> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> If you tell us exactly what you are trying to achieve, we will tell you what
> is possible.
>
> --
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Graham Mayor - Word MVP
>
> My web site www.gmayor.com
> Word MVP web site http://word.mvps.org
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>
> sos-DC wrote:
> > I previously tried that but could not get it to work.
> > I did notice that the original field brackets {} hand lines around
> > them but the ones I entered did NOT. Could that make a difference?
> >
> > I checked the link you provided but an unable to find anything. I'm
> > not very good at searching the web.
> >
> > "Graham Mayor" wrote:
> >
> >> If you are building complex conditional fields, it is better to
> >> insert them manually using CTRL+F9 for each set of field brackets
> >> {}. The field dialogs are too inflexible. See
> >> http://www.gmayor.com/formatting_word_fields.htm for some examples
> >> of field construction.
> >>
> >> --
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> Graham Mayor - Word MVP
> >>
> >> My web site www.gmayor.com
> >> Word MVP web site http://word.mvps.org
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>
> >> sos-DC wrote:
> >>> Under
> >>>
> >>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool bar)
> >>> is
> >>>
> >>> If...Then...Else...
> >>>
> >>> This window allows for adding text under specific circumstances.
> >>>
> >>> During an online class for Mail Merge, I was shown a similar window,
> >>> but instead of inserting text, you would add Mergefields.
> >>>
> >>> The window had the first row (Field name, Comparison, Compare to) or
> >>> something similar on the succeeding rows.
> >>>
> >>> I didn't realize I did not know where it is and I would like to find
> >>> it.
> >>>
> >>> If this makes sense, can anyone tell me how to open this window? I
> >>> have no way of reconnecting with the instructor for the online
> >>> class.

Re: Mail Merge [If...Then...Else...]
sos-DC 6/11/2007 6:30:02 PM
You're right - it would help if you knew what I was trying to achieve.

The data base is in Excel, slightly over 400 entries.

There are separate columns for HOME addresses and WORK addresses.

Most of the entries have home addresses only, approximately 325.

The rest are WORK addresses only or both HOME and WORK addresses provided.

What I am trying to do is create a Mail Merge document that will print the
home addresses. If the home address column is blank it will automatically go
to the work address columns.

I have created a great many additional columns (17 columns) into which I
entered a great many formulas so that I can use just one merge document for
the entire data base. (Haven't tested it yet.)

I am hoping to find a simple way to use IF...THEN...ELSE... in Word (MERGE)
to handle the problem.

I'm comfortable with Excel but the next person to take over the task may not
be and the extra columns will definitely confuse them.

Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
problem.


"Graham Mayor" wrote:

[Quoted Text]
> The basics of mail merge are covered at
> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> If you tell us exactly what you are trying to achieve, we will tell you what
> is possible.
>
> --
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Graham Mayor - Word MVP
>
> My web site www.gmayor.com
> Word MVP web site http://word.mvps.org
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>
> sos-DC wrote:
> > I previously tried that but could not get it to work.
> > I did notice that the original field brackets {} hand lines around
> > them but the ones I entered did NOT. Could that make a difference?
> >
> > I checked the link you provided but an unable to find anything. I'm
> > not very good at searching the web.
> >
> > "Graham Mayor" wrote:
> >
> >> If you are building complex conditional fields, it is better to
> >> insert them manually using CTRL+F9 for each set of field brackets
> >> {}. The field dialogs are too inflexible. See
> >> http://www.gmayor.com/formatting_word_fields.htm for some examples
> >> of field construction.
> >>
> >> --
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> Graham Mayor - Word MVP
> >>
> >> My web site www.gmayor.com
> >> Word MVP web site http://word.mvps.org
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>
> >> sos-DC wrote:
> >>> Under
> >>>
> >>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool bar)
> >>> is
> >>>
> >>> If...Then...Else...
> >>>
> >>> This window allows for adding text under specific circumstances.
> >>>
> >>> During an online class for Mail Merge, I was shown a similar window,
> >>> but instead of inserting text, you would add Mergefields.
> >>>
> >>> The window had the first row (Field name, Comparison, Compare to) or
> >>> something similar on the succeeding rows.
> >>>
> >>> I didn't realize I did not know where it is and I would like to find
> >>> it.
> >>>
> >>> If this makes sense, can anyone tell me how to open this window? I
> >>> have no way of reconnecting with the instructor for the online
> >>> class.
>
>
>
Re: Mail Merge [If...Then...Else...]
"Graham Mayor" <gmayor[ at ]REMOVETHISmvps.org> 6/12/2007 6:27:05 AM
The basic setup is

{IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}

however this assumes that the whole address is in one field. If you have
separate streets for streets, towns etc, test one of the home fields that
should always be present (such as the town) and put all the fields that
represent the addresses formatted as you require them between the quotes.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>


sos-DC wrote:
[Quoted Text]
> You're right - it would help if you knew what I was trying to achieve.
>
> The data base is in Excel, slightly over 400 entries.
>
> There are separate columns for HOME addresses and WORK addresses.
>
> Most of the entries have home addresses only, approximately 325.
>
> The rest are WORK addresses only or both HOME and WORK addresses
> provided.
>
> What I am trying to do is create a Mail Merge document that will
> print the home addresses. If the home address column is blank it will
> automatically go to the work address columns.
>
> I have created a great many additional columns (17 columns) into
> which I entered a great many formulas so that I can use just one
> merge document for the entire data base. (Haven't tested it yet.)
>
> I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> (MERGE) to handle the problem.
>
> I'm comfortable with Excel but the next person to take over the task
> may not be and the extra columns will definitely confuse them.
>
> Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
> problem.
>
>
> "Graham Mayor" wrote:
>
>> The basics of mail merge are covered at
>> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
>> If you tell us exactly what you are trying to achieve, we will tell
>> you what is possible.
>>
>> --
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> Graham Mayor - Word MVP
>>
>> My web site www.gmayor.com
>> Word MVP web site http://word.mvps.org
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>
>> sos-DC wrote:
>>> I previously tried that but could not get it to work.
>>> I did notice that the original field brackets {} hand lines around
>>> them but the ones I entered did NOT. Could that make a difference?
>>>
>>> I checked the link you provided but an unable to find anything. I'm
>>> not very good at searching the web.
>>>
>>> "Graham Mayor" wrote:
>>>
>>>> If you are building complex conditional fields, it is better to
>>>> insert them manually using CTRL+F9 for each set of field brackets
>>>> {}. The field dialogs are too inflexible. See
>>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
>>>> of field construction.
>>>>
>>>> --
>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>> Graham Mayor - Word MVP
>>>>
>>>> My web site www.gmayor.com
>>>> Word MVP web site http://word.mvps.org
>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>
>>>> sos-DC wrote:
>>>>> Under
>>>>>
>>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
>>>>> bar) is
>>>>>
>>>>> If...Then...Else...
>>>>>
>>>>> This window allows for adding text under specific circumstances.
>>>>>
>>>>> During an online class for Mail Merge, I was shown a similar
>>>>> window, but instead of inserting text, you would add Mergefields.
>>>>>
>>>>> The window had the first row (Field name, Comparison, Compare to)
>>>>> or something similar on the succeeding rows.
>>>>>
>>>>> I didn't realize I did not know where it is and I would like to
>>>>> find it.
>>>>>
>>>>> If this makes sense, can anyone tell me how to open this window? I
>>>>> have no way of reconnecting with the instructor for the online
>>>>> class.


Re: Mail Merge [If...Then...Else...]
sos-DC 6/12/2007 1:44:01 PM
Now the only question is where and how do I enter it. I tried under Insert
Merge Field, but the "IF" field does not allow you to enter a formula. I
entered data as was suggested by someone in my office and then did ALT-F9 to
view and edit.

The brackets {} in the first part of the formula have a faint box around
them but the ones I entered did not.

This is my actual problem. I'm pretty good with formulas in Excel so
eventually I would have figured it out (I hope), but knowing where and how to
enter the formula is my current problem.

Thanks for any help you can give.

"Graham Mayor" wrote:

[Quoted Text]
> The basic setup is
>
> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
>
> however this assumes that the whole address is in one field. If you have
> separate streets for streets, towns etc, test one of the home fields that
> should always be present (such as the town) and put all the fields that
> represent the addresses formatted as you require them between the quotes.
>
> --
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Graham Mayor - Word MVP
>
> My web site www.gmayor.com
> Word MVP web site http://word.mvps.org
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>
>
> sos-DC wrote:
> > You're right - it would help if you knew what I was trying to achieve.
> >
> > The data base is in Excel, slightly over 400 entries.
> >
> > There are separate columns for HOME addresses and WORK addresses.
> >
> > Most of the entries have home addresses only, approximately 325.
> >
> > The rest are WORK addresses only or both HOME and WORK addresses
> > provided.
> >
> > What I am trying to do is create a Mail Merge document that will
> > print the home addresses. If the home address column is blank it will
> > automatically go to the work address columns.
> >
> > I have created a great many additional columns (17 columns) into
> > which I entered a great many formulas so that I can use just one
> > merge document for the entire data base. (Haven't tested it yet.)
> >
> > I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> > (MERGE) to handle the problem.
> >
> > I'm comfortable with Excel but the next person to take over the task
> > may not be and the extra columns will definitely confuse them.
> >
> > Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
> > problem.
> >
> >
> > "Graham Mayor" wrote:
> >
> >> The basics of mail merge are covered at
> >> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> >> If you tell us exactly what you are trying to achieve, we will tell
> >> you what is possible.
> >>
> >> --
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> Graham Mayor - Word MVP
> >>
> >> My web site www.gmayor.com
> >> Word MVP web site http://word.mvps.org
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>
> >> sos-DC wrote:
> >>> I previously tried that but could not get it to work.
> >>> I did notice that the original field brackets {} hand lines around
> >>> them but the ones I entered did NOT. Could that make a difference?
> >>>
> >>> I checked the link you provided but an unable to find anything. I'm
> >>> not very good at searching the web.
> >>>
> >>> "Graham Mayor" wrote:
> >>>
> >>>> If you are building complex conditional fields, it is better to
> >>>> insert them manually using CTRL+F9 for each set of field brackets
> >>>> {}. The field dialogs are too inflexible. See
> >>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
> >>>> of field construction.
> >>>>
> >>>> --
> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>> Graham Mayor - Word MVP
> >>>>
> >>>> My web site www.gmayor.com
> >>>> Word MVP web site http://word.mvps.org
> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>
> >>>> sos-DC wrote:
> >>>>> Under
> >>>>>
> >>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
> >>>>> bar) is
> >>>>>
> >>>>> If...Then...Else...
> >>>>>
> >>>>> This window allows for adding text under specific circumstances.
> >>>>>
> >>>>> During an online class for Mail Merge, I was shown a similar
> >>>>> window, but instead of inserting text, you would add Mergefields.
> >>>>>
> >>>>> The window had the first row (Field name, Comparison, Compare to)
> >>>>> or something similar on the succeeding rows.
> >>>>>
> >>>>> I didn't realize I did not know where it is and I would like to
> >>>>> find it.
> >>>>>
> >>>>> If this makes sense, can anyone tell me how to open this window? I
> >>>>> have no way of reconnecting with the instructor for the online
> >>>>> class.
>
>
>
Re: Mail Merge [If...Then...Else...]
"Graham Mayor" <gmayor[ at ]REMOVETHISmvps.org> 6/12/2007 2:34:21 PM
If you step back to my second post in this thread, all is explained. Enter
the fields directly into the document from the keyboard using CTRL+F9 for
each pair of brackets {} (four pairs in the example I posted).

Forget the dialogs (though you can use the insert > merge field dialog to
confirm the spelling of any fields used) insert the lot manually at the
location where you want it to appear.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>


sos-DC wrote:
[Quoted Text]
> Now the only question is where and how do I enter it. I tried under
> Insert Merge Field, but the "IF" field does not allow you to enter a
> formula. I entered data as was suggested by someone in my office and
> then did ALT-F9 to view and edit.
>
> The brackets {} in the first part of the formula have a faint box
> around them but the ones I entered did not.
>
> This is my actual problem. I'm pretty good with formulas in Excel so
> eventually I would have figured it out (I hope), but knowing where
> and how to enter the formula is my current problem.
>
> Thanks for any help you can give.
>
> "Graham Mayor" wrote:
>
>> The basic setup is
>>
>> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
>>
>> however this assumes that the whole address is in one field. If you
>> have separate streets for streets, towns etc, test one of the home
>> fields that should always be present (such as the town) and put all
>> the fields that represent the addresses formatted as you require
>> them between the quotes.
>>
>> --
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> Graham Mayor - Word MVP
>>
>> My web site www.gmayor.com
>> Word MVP web site http://word.mvps.org
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>
>>
>> sos-DC wrote:
>>> You're right - it would help if you knew what I was trying to
>>> achieve.
>>>
>>> The data base is in Excel, slightly over 400 entries.
>>>
>>> There are separate columns for HOME addresses and WORK addresses.
>>>
>>> Most of the entries have home addresses only, approximately 325.
>>>
>>> The rest are WORK addresses only or both HOME and WORK addresses
>>> provided.
>>>
>>> What I am trying to do is create a Mail Merge document that will
>>> print the home addresses. If the home address column is blank it
>>> will automatically go to the work address columns.
>>>
>>> I have created a great many additional columns (17 columns) into
>>> which I entered a great many formulas so that I can use just one
>>> merge document for the entire data base. (Haven't tested it yet.)
>>>
>>> I am hoping to find a simple way to use IF...THEN...ELSE... in Word
>>> (MERGE) to handle the problem.
>>>
>>> I'm comfortable with Excel but the next person to take over the task
>>> may not be and the extra columns will definitely confuse them.
>>>
>>> Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve
>>> my problem.
>>>
>>>
>>> "Graham Mayor" wrote:
>>>
>>>> The basics of mail merge are covered at
>>>> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
>>>> If you tell us exactly what you are trying to achieve, we will tell
>>>> you what is possible.
>>>>
>>>> --
>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>> Graham Mayor - Word MVP
>>>>
>>>> My web site www.gmayor.com
>>>> Word MVP web site http://word.mvps.org
>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>
>>>> sos-DC wrote:
>>>>> I previously tried that but could not get it to work.
>>>>> I did notice that the original field brackets {} hand lines around
>>>>> them but the ones I entered did NOT. Could that make a difference?
>>>>>
>>>>> I checked the link you provided but an unable to find anything.
>>>>> I'm not very good at searching the web.
>>>>>
>>>>> "Graham Mayor" wrote:
>>>>>
>>>>>> If you are building complex conditional fields, it is better to
>>>>>> insert them manually using CTRL+F9 for each set of field brackets
>>>>>> {}. The field dialogs are too inflexible. See
>>>>>> http://www.gmayor.com/formatting_word_fields.htm for some
>>>>>> examples of field construction.
>>>>>>
>>>>>> --
>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>> Graham Mayor - Word MVP
>>>>>>
>>>>>> My web site www.gmayor.com
>>>>>> Word MVP web site http://word.mvps.org
>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>
>>>>>> sos-DC wrote:
>>>>>>> Under
>>>>>>>
>>>>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
>>>>>>> bar) is
>>>>>>>
>>>>>>> If...Then...Else...
>>>>>>>
>>>>>>> This window allows for adding text under specific circumstances.
>>>>>>>
>>>>>>> During an online class for Mail Merge, I was shown a similar
>>>>>>> window, but instead of inserting text, you would add
>>>>>>> Mergefields.
>>>>>>>
>>>>>>> The window had the first row (Field name, Comparison, Compare
>>>>>>> to) or something similar on the succeeding rows.
>>>>>>>
>>>>>>> I didn't realize I did not know where it is and I would like to
>>>>>>> find it.
>>>>>>>
>>>>>>> If this makes sense, can anyone tell me how to open this
>>>>>>> window? I have no way of reconnecting with the instructor for
>>>>>>> the online class.


Re: Mail Merge [If...Then...Else...]
"Graham Mayor" <gmayor[ at ]REMOVETHISmvps.org> 6/12/2007 2:37:35 PM
Make that my *first* post in this thread ;)

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

Graham Mayor wrote:
[Quoted Text]
> If you step back to my second post in this thread, all is explained.
> Enter the fields directly into the document from the keyboard using
> CTRL+F9 for each pair of brackets {} (four pairs in the example I
> posted).
> Forget the dialogs (though you can use the insert > merge field
> dialog to confirm the spelling of any fields used) insert the lot
> manually at the location where you want it to appear.
>
>
> sos-DC wrote:
>> Now the only question is where and how do I enter it. I tried under
>> Insert Merge Field, but the "IF" field does not allow you to enter a
>> formula. I entered data as was suggested by someone in my office and
>> then did ALT-F9 to view and edit.
>>
>> The brackets {} in the first part of the formula have a faint box
>> around them but the ones I entered did not.
>>
>> This is my actual problem. I'm pretty good with formulas in Excel so
>> eventually I would have figured it out (I hope), but knowing where
>> and how to enter the formula is my current problem.
>>
>> Thanks for any help you can give.
>>
>> "Graham Mayor" wrote:
>>
>>> The basic setup is
>>>
>>> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
>>>
>>> however this assumes that the whole address is in one field. If you
>>> have separate streets for streets, towns etc, test one of the home
>>> fields that should always be present (such as the town) and put all
>>> the fields that represent the addresses formatted as you require
>>> them between the quotes.
>>>
>>> --
>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>> Graham Mayor - Word MVP
>>>
>>> My web site www.gmayor.com
>>> Word MVP web site http://word.mvps.org
>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>
>>>
>>> sos-DC wrote:
>>>> You're right - it would help if you knew what I was trying to
>>>> achieve.
>>>>
>>>> The data base is in Excel, slightly over 400 entries.
>>>>
>>>> There are separate columns for HOME addresses and WORK addresses.
>>>>
>>>> Most of the entries have home addresses only, approximately 325.
>>>>
>>>> The rest are WORK addresses only or both HOME and WORK addresses
>>>> provided.
>>>>
>>>> What I am trying to do is create a Mail Merge document that will
>>>> print the home addresses. If the home address column is blank it
>>>> will automatically go to the work address columns.
>>>>
>>>> I have created a great many additional columns (17 columns) into
>>>> which I entered a great many formulas so that I can use just one
>>>> merge document for the entire data base. (Haven't tested it yet.)
>>>>
>>>> I am hoping to find a simple way to use IF...THEN...ELSE... in Word
>>>> (MERGE) to handle the problem.
>>>>
>>>> I'm comfortable with Excel but the next person to take over the
>>>> task may not be and the extra columns will definitely confuse them.
>>>>
>>>> Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve
>>>> my problem.
>>>>
>>>>
>>>> "Graham Mayor" wrote:
>>>>
>>>>> The basics of mail merge are covered at
>>>>> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
>>>>> If you tell us exactly what you are trying to achieve, we will
>>>>> tell you what is possible.
>>>>>
>>>>> --
>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>> Graham Mayor - Word MVP
>>>>>
>>>>> My web site www.gmayor.com
>>>>> Word MVP web site http://word.mvps.org
>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>
>>>>> sos-DC wrote:
>>>>>> I previously tried that but could not get it to work.
>>>>>> I did notice that the original field brackets {} hand lines
>>>>>> around them but the ones I entered did NOT. Could that make a
>>>>>> difference? I checked the link you provided but an unable to find
>>>>>> anything.
>>>>>> I'm not very good at searching the web.
>>>>>>
>>>>>> "Graham Mayor" wrote:
>>>>>>
>>>>>>> If you are building complex conditional fields, it is better to
>>>>>>> insert them manually using CTRL+F9 for each set of field
>>>>>>> brackets {}. The field dialogs are too inflexible. See
>>>>>>> http://www.gmayor.com/formatting_word_fields.htm for some
>>>>>>> examples of field construction.
>>>>>>>
>>>>>>> --
>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>> Graham Mayor - Word MVP
>>>>>>>
>>>>>>> My web site www.gmayor.com
>>>>>>> Word MVP web site http://word.mvps.org
>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>>
>>>>>>> sos-DC wrote:
>>>>>>>> Under
>>>>>>>>
>>>>>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
>>>>>>>> bar) is
>>>>>>>>
>>>>>>>> If...Then...Else...
>>>>>>>>
>>>>>>>> This window allows for adding text under specific
>>>>>>>> circumstances. During an online class for Mail Merge, I was shown a
>>>>>>>> similar
>>>>>>>> window, but instead of inserting text, you would add
>>>>>>>> Mergefields.
>>>>>>>>
>>>>>>>> The window had the first row (Field name, Comparison, Compare
>>>>>>>> to) or something similar on the succeeding rows.
>>>>>>>>
>>>>>>>> I didn't realize I did not know where it is and I would like to
>>>>>>>> find it.
>>>>>>>>
>>>>>>>> If this makes sense, can anyone tell me how to open this
>>>>>>>> window? I have no way of reconnecting with the instructor for
>>>>>>>> the online class.


Re: Mail Merge [If...Then...Else...]
sos-DC 6/13/2007 2:10:05 PM
Perfect. It works.
My major problem was I misread Ctrl+F9 for Alt+F9
People tend to read what they expect and not necessarily with is.

Thank you VERY much for your help and patience.


"Graham Mayor" wrote:

[Quoted Text]
> Make that my *first* post in this thread ;)
>
> --
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Graham Mayor - Word MVP
>
> My web site www.gmayor.com
> Word MVP web site http://word.mvps.org
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>
> Graham Mayor wrote:
> > If you step back to my second post in this thread, all is explained.
> > Enter the fields directly into the document from the keyboard using
> > CTRL+F9 for each pair of brackets {} (four pairs in the example I
> > posted).
> > Forget the dialogs (though you can use the insert > merge field
> > dialog to confirm the spelling of any fields used) insert the lot
> > manually at the location where you want it to appear.
> >
> >
> > sos-DC wrote:
> >> Now the only question is where and how do I enter it. I tried under
> >> Insert Merge Field, but the "IF" field does not allow you to enter a
> >> formula. I entered data as was suggested by someone in my office and
> >> then did ALT-F9 to view and edit.
> >>
> >> The brackets {} in the first part of the formula have a faint box
> >> around them but the ones I entered did not.
> >>
> >> This is my actual problem. I'm pretty good with formulas in Excel so
> >> eventually I would have figured it out (I hope), but knowing where
> >> and how to enter the formula is my current problem.
> >>
> >> Thanks for any help you can give.
> >>
> >> "Graham Mayor" wrote:
> >>
> >>> The basic setup is
> >>>
> >>> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
> >>>
> >>> however this assumes that the whole address is in one field. If you
> >>> have separate streets for streets, towns etc, test one of the home
> >>> fields that should always be present (such as the town) and put all
> >>> the fields that represent the addresses formatted as you require
> >>> them between the quotes.
> >>>
> >>> --
> >>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>> Graham Mayor - Word MVP
> >>>
> >>> My web site www.gmayor.com
> >>> Word MVP web site http://word.mvps.org
> >>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>
> >>>
> >>> sos-DC wrote:
> >>>> You're right - it would help if you knew what I was trying to
> >>>> achieve.
> >>>>
> >>>> The data base is in Excel, slightly over 400 entries.
> >>>>
> >>>> There are separate columns for HOME addresses and WORK addresses.
> >>>>
> >>>> Most of the entries have home addresses only, approximately 325.
> >>>>
> >>>> The rest are WORK addresses only or both HOME and WORK addresses
> >>>> provided.
> >>>>
> >>>> What I am trying to do is create a Mail Merge document that will
> >>>> print the home addresses. If the home address column is blank it
> >>>> will automatically go to the work address columns.
> >>>>
> >>>> I have created a great many additional columns (17 columns) into
> >>>> which I entered a great many formulas so that I can use just one
> >>>> merge document for the entire data base. (Haven't tested it yet.)
> >>>>
> >>>> I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> >>>> (MERGE) to handle the problem.
> >>>>
> >>>> I'm comfortable with Excel but the next person to take over the
> >>>> task may not be and the extra columns will definitely confuse them.
> >>>>
> >>>> Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve
> >>>> my problem.
> >>>>
> >>>>
> >>>> "Graham Mayor" wrote:
> >>>>
> >>>>> The basics of mail merge are covered at
> >>>>> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> >>>>> If you tell us exactly what you are trying to achieve, we will
> >>>>> tell you what is possible.
> >>>>>
> >>>>> --
> >>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>> Graham Mayor - Word MVP
> >>>>>
> >>>>> My web site www.gmayor.com
> >>>>> Word MVP web site http://word.mvps.org
> >>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>
> >>>>> sos-DC wrote:
> >>>>>> I previously tried that but could not get it to work.
> >>>>>> I did notice that the original field brackets {} hand lines
> >>>>>> around them but the ones I entered did NOT. Could that make a
> >>>>>> difference? I checked the link you provided but an unable to find
> >>>>>> anything.
> >>>>>> I'm not very good at searching the web.
> >>>>>>
> >>>>>> "Graham Mayor" wrote:
> >>>>>>
> >>>>>>> If you are building complex conditional fields, it is better to
> >>>>>>> insert them manually using CTRL+F9 for each set of field
> >>>>>>> brackets {}. The field dialogs are too inflexible. See
> >>>>>>> http://www.gmayor.com/formatting_word_fields.htm for some
> >>>>>>> examples of field construction.
> >>>>>>>
> >>>>>>> --
> >>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>>> Graham Mayor - Word MVP
> >>>>>>>
> >>>>>>> My web site www.gmayor.com
> >>>>>>> Word MVP web site http://word.mvps.org
> >>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>>>
> >>>>>>> sos-DC wrote:
> >>>>>>>> Under
> >>>>>>>>
> >>>>>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
> >>>>>>>> bar) is
> >>>>>>>>
> >>>>>>>> If...Then...Else...
> >>>>>>>>
> >>>>>>>> This window allows for adding text under specific
> >>>>>>>> circumstances. During an online class for Mail Merge, I was shown a
> >>>>>>>> similar
> >>>>>>>> window, but instead of inserting text, you would add
> >>>>>>>> Mergefields.
> >>>>>>>>
> >>>>>>>> The window had the first row (Field name, Comparison, Compare
> >>>>>>>> to) or something similar on the succeeding rows.
> >>>>>>>>
> >>>>>>>> I didn't realize I did not know where it is and I would like to
> >>>>>>>> find it.
> >>>>>>>>
> >>>>>>>> If this makes sense, can anyone tell me how to open this
> >>>>>>>> window? I have no way of reconnecting with the instructor for
> >>>>>>>> the online class.
>
>
>
Re: Mail Merge [If...Then...Else...]
danhattan 6/13/2007 4:41:01 PM
Hello. I had a question similar to the original poster and have followed this
thread to the end. It seems like I know what I'm doing but there must be
something wrong with my syntax as I'm not getting all the results I'd expect.
My field is constructed like this:
{ IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }

The idea is to print the Spouse field if there's data present, and print
nothing if data isn't present.

If there's nothing in the Spouse field, this works perfectly. The problem is
that if there is data, rather than printing the field data, the field result
is {MERGEFIELD Spouse}, i.e. what's literally between the quotation marks.

My syntax looks right to my eye, but I'm clearly missing something. Any help
you could lend would be much appreciated. Thank you.

"Graham Mayor" wrote:

[Quoted Text]
> The basic setup is
>
> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
>
> however this assumes that the whole address is in one field. If you have
> separate streets for streets, towns etc, test one of the home fields that
> should always be present (such as the town) and put all the fields that
> represent the addresses formatted as you require them between the quotes.
>
> --
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Graham Mayor - Word MVP
>
> My web site www.gmayor.com
> Word MVP web site http://word.mvps.org
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>
>
> sos-DC wrote:
> > You're right - it would help if you knew what I was trying to achieve.
> >
> > The data base is in Excel, slightly over 400 entries.
> >
> > There are separate columns for HOME addresses and WORK addresses.
> >
> > Most of the entries have home addresses only, approximately 325.
> >
> > The rest are WORK addresses only or both HOME and WORK addresses
> > provided.
> >
> > What I am trying to do is create a Mail Merge document that will
> > print the home addresses. If the home address column is blank it will
> > automatically go to the work address columns.
> >
> > I have created a great many additional columns (17 columns) into
> > which I entered a great many formulas so that I can use just one
> > merge document for the entire data base. (Haven't tested it yet.)
> >
> > I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> > (MERGE) to handle the problem.
> >
> > I'm comfortable with Excel but the next person to take over the task
> > may not be and the extra columns will definitely confuse them.
> >
> > Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
> > problem.
> >
> >
> > "Graham Mayor" wrote:
> >
> >> The basics of mail merge are covered at
> >> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> >> If you tell us exactly what you are trying to achieve, we will tell
> >> you what is possible.
> >>
> >> --
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> Graham Mayor - Word MVP
> >>
> >> My web site www.gmayor.com
> >> Word MVP web site http://word.mvps.org
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>
> >> sos-DC wrote:
> >>> I previously tried that but could not get it to work.
> >>> I did notice that the original field brackets {} hand lines around
> >>> them but the ones I entered did NOT. Could that make a difference?
> >>>
> >>> I checked the link you provided but an unable to find anything. I'm
> >>> not very good at searching the web.
> >>>
> >>> "Graham Mayor" wrote:
> >>>
> >>>> If you are building complex conditional fields, it is better to
> >>>> insert them manually using CTRL+F9 for each set of field brackets
> >>>> {}. The field dialogs are too inflexible. See
> >>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
> >>>> of field construction.
> >>>>
> >>>> --
> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>> Graham Mayor - Word MVP
> >>>>
> >>>> My web site www.gmayor.com
> >>>> Word MVP web site http://word.mvps.org
> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>
> >>>> sos-DC wrote:
> >>>>> Under
> >>>>>
> >>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
> >>>>> bar) is
> >>>>>
> >>>>> If...Then...Else...
> >>>>>
> >>>>> This window allows for adding text under specific circumstances.
> >>>>>
> >>>>> During an online class for Mail Merge, I was shown a similar
> >>>>> window, but instead of inserting text, you would add Mergefields.
> >>>>>
> >>>>> The window had the first row (Field name, Comparison, Compare to)
> >>>>> or something similar on the succeeding rows.
> >>>>>
> >>>>> I didn't realize I did not know where it is and I would like to
> >>>>> find it.
> >>>>>
> >>>>> If this makes sense, can anyone tell me how to open this window? I
> >>>>> have no way of reconnecting with the instructor for the online
> >>>>> class.
>
>
>
Re: Mail Merge [If...Then...Else...]
"Peter Jamieson" <pjj[ at ]KillmapSpjjnet.demon.co.uk> 6/13/2007 5:18:21 PM
You have to use ctrl-F9 to enter /every/ pair of the special field code
braces. In this case, that's 3 pairs of the braces.

Peter Jamieson
"danhattan" <hatinonya[ at ]screwthespammers.com> wrote in message
news:189BC987-0883-468A-9217-CBD3D0741DEA[ at ]microsoft.com...
[Quoted Text]
> Hello. I had a question similar to the original poster and have followed
> this
> thread to the end. It seems like I know what I'm doing but there must be
> something wrong with my syntax as I'm not getting all the results I'd
> expect.
> My field is constructed like this:
> { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }
>
> The idea is to print the Spouse field if there's data present, and print
> nothing if data isn't present.
>
> If there's nothing in the Spouse field, this works perfectly. The problem
> is
> that if there is data, rather than printing the field data, the field
> result
> is {MERGEFIELD Spouse}, i.e. what's literally between the quotation marks.
>
> My syntax looks right to my eye, but I'm clearly missing something. Any
> help
> you could lend would be much appreciated. Thank you.
>
> "Graham Mayor" wrote:
>
>> The basic setup is
>>
>> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
>>
>> however this assumes that the whole address is in one field. If you have
>> separate streets for streets, towns etc, test one of the home fields that
>> should always be present (such as the town) and put all the fields that
>> represent the addresses formatted as you require them between the quotes.
>>
>> --
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> Graham Mayor - Word MVP
>>
>> My web site www.gmayor.com
>> Word MVP web site http://word.mvps.org
>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>
>>
>> sos-DC wrote:
>> > You're right - it would help if you knew what I was trying to achieve.
>> >
>> > The data base is in Excel, slightly over 400 entries.
>> >
>> > There are separate columns for HOME addresses and WORK addresses.
>> >
>> > Most of the entries have home addresses only, approximately 325.
>> >
>> > The rest are WORK addresses only or both HOME and WORK addresses
>> > provided.
>> >
>> > What I am trying to do is create a Mail Merge document that will
>> > print the home addresses. If the home address column is blank it will
>> > automatically go to the work address columns.
>> >
>> > I have created a great many additional columns (17 columns) into
>> > which I entered a great many formulas so that I can use just one
>> > merge document for the entire data base. (Haven't tested it yet.)
>> >
>> > I am hoping to find a simple way to use IF...THEN...ELSE... in Word
>> > (MERGE) to handle the problem.
>> >
>> > I'm comfortable with Excel but the next person to take over the task
>> > may not be and the extra columns will definitely confuse them.
>> >
>> > Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
>> > problem.
>> >
>> >
>> > "Graham Mayor" wrote:
>> >
>> >> The basics of mail merge are covered at
>> >> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
>> >> If you tell us exactly what you are trying to achieve, we will tell
>> >> you what is possible.
>> >>
>> >> --
>> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> >> Graham Mayor - Word MVP
>> >>
>> >> My web site www.gmayor.com
>> >> Word MVP web site http://word.mvps.org
>> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> >>
>> >> sos-DC wrote:
>> >>> I previously tried that but could not get it to work.
>> >>> I did notice that the original field brackets {} hand lines around
>> >>> them but the ones I entered did NOT. Could that make a difference?
>> >>>
>> >>> I checked the link you provided but an unable to find anything. I'm
>> >>> not very good at searching the web.
>> >>>
>> >>> "Graham Mayor" wrote:
>> >>>
>> >>>> If you are building complex conditional fields, it is better to
>> >>>> insert them manually using CTRL+F9 for each set of field brackets
>> >>>> {}. The field dialogs are too inflexible. See
>> >>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
>> >>>> of field construction.
>> >>>>
>> >>>> --
>> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> >>>> Graham Mayor - Word MVP
>> >>>>
>> >>>> My web site www.gmayor.com
>> >>>> Word MVP web site http://word.mvps.org
>> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>> >>>>
>> >>>> sos-DC wrote:
>> >>>>> Under
>> >>>>>
>> >>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
>> >>>>> bar) is
>> >>>>>
>> >>>>> If...Then...Else...
>> >>>>>
>> >>>>> This window allows for adding text under specific circumstances.
>> >>>>>
>> >>>>> During an online class for Mail Merge, I was shown a similar
>> >>>>> window, but instead of inserting text, you would add Mergefields.
>> >>>>>
>> >>>>> The window had the first row (Field name, Comparison, Compare to)
>> >>>>> or something similar on the succeeding rows.
>> >>>>>
>> >>>>> I didn't realize I did not know where it is and I would like to
>> >>>>> find it.
>> >>>>>
>> >>>>> If this makes sense, can anyone tell me how to open this window? I
>> >>>>> have no way of reconnecting with the instructor for the online
>> >>>>> class.
>>
>>
>>

Re: Mail Merge [If...Then...Else...]
danhattan 6/13/2007 6:08:01 PM
I appreciate the reply, but apparently don't quite understand. In the example
I posted there are 3 pairs of braces. When I compare my syntax to Graham's
there doesn't appear to be a difference except that his False conditions
prints another field whereas mine simply prints nothing.

Again, what am I missing here?

"Peter Jamieson" wrote:

[Quoted Text]
> You have to use ctrl-F9 to enter /every/ pair of the special field code
> braces. In this case, that's 3 pairs of the braces.
>
> Peter Jamieson
> "danhattan" <hatinonya[ at ]screwthespammers.com> wrote in message
> news:189BC987-0883-468A-9217-CBD3D0741DEA[ at ]microsoft.com...
> > Hello. I had a question similar to the original poster and have followed
> > this
> > thread to the end. It seems like I know what I'm doing but there must be
> > something wrong with my syntax as I'm not getting all the results I'd
> > expect.
> > My field is constructed like this:
> > { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }
> >
> > The idea is to print the Spouse field if there's data present, and print
> > nothing if data isn't present.
> >
> > If there's nothing in the Spouse field, this works perfectly. The problem
> > is
> > that if there is data, rather than printing the field data, the field
> > result
> > is {MERGEFIELD Spouse}, i.e. what's literally between the quotation marks.
> >
> > My syntax looks right to my eye, but I'm clearly missing something. Any
> > help
> > you could lend would be much appreciated. Thank you.
> >
> > "Graham Mayor" wrote:
> >
> >> The basic setup is
> >>
> >> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
> >>
> >> however this assumes that the whole address is in one field. If you have
> >> separate streets for streets, towns etc, test one of the home fields that
> >> should always be present (such as the town) and put all the fields that
> >> represent the addresses formatted as you require them between the quotes.
> >>
> >> --
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> Graham Mayor - Word MVP
> >>
> >> My web site www.gmayor.com
> >> Word MVP web site http://word.mvps.org
> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>
> >>
> >> sos-DC wrote:
> >> > You're right - it would help if you knew what I was trying to achieve.
> >> >
> >> > The data base is in Excel, slightly over 400 entries.
> >> >
> >> > There are separate columns for HOME addresses and WORK addresses.
> >> >
> >> > Most of the entries have home addresses only, approximately 325.
> >> >
> >> > The rest are WORK addresses only or both HOME and WORK addresses
> >> > provided.
> >> >
> >> > What I am trying to do is create a Mail Merge document that will
> >> > print the home addresses. If the home address column is blank it will
> >> > automatically go to the work address columns.
> >> >
> >> > I have created a great many additional columns (17 columns) into
> >> > which I entered a great many formulas so that I can use just one
> >> > merge document for the entire data base. (Haven't tested it yet.)
> >> >
> >> > I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> >> > (MERGE) to handle the problem.
> >> >
> >> > I'm comfortable with Excel but the next person to take over the task
> >> > may not be and the extra columns will definitely confuse them.
> >> >
> >> > Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
> >> > problem.
> >> >
> >> >
> >> > "Graham Mayor" wrote:
> >> >
> >> >> The basics of mail merge are covered at
> >> >> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> >> >> If you tell us exactly what you are trying to achieve, we will tell
> >> >> you what is possible.
> >> >>
> >> >> --
> >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> >> Graham Mayor - Word MVP
> >> >>
> >> >> My web site www.gmayor.com
> >> >> Word MVP web site http://word.mvps.org
> >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> >>
> >> >> sos-DC wrote:
> >> >>> I previously tried that but could not get it to work.
> >> >>> I did notice that the original field brackets {} hand lines around
> >> >>> them but the ones I entered did NOT. Could that make a difference?
> >> >>>
> >> >>> I checked the link you provided but an unable to find anything. I'm
> >> >>> not very good at searching the web.
> >> >>>
> >> >>> "Graham Mayor" wrote:
> >> >>>
> >> >>>> If you are building complex conditional fields, it is better to
> >> >>>> insert them manually using CTRL+F9 for each set of field brackets
> >> >>>> {}. The field dialogs are too inflexible. See
> >> >>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
> >> >>>> of field construction.
> >> >>>>
> >> >>>> --
> >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> >>>> Graham Mayor - Word MVP
> >> >>>>
> >> >>>> My web site www.gmayor.com
> >> >>>> Word MVP web site http://word.mvps.org
> >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >> >>>>
> >> >>>> sos-DC wrote:
> >> >>>>> Under
> >> >>>>>
> >> >>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
> >> >>>>> bar) is
> >> >>>>>
> >> >>>>> If...Then...Else...
> >> >>>>>
> >> >>>>> This window allows for adding text under specific circumstances.
> >> >>>>>
> >> >>>>> During an online class for Mail Merge, I was shown a similar
> >> >>>>> window, but instead of inserting text, you would add Mergefields.
> >> >>>>>
> >> >>>>> The window had the first row (Field name, Comparison, Compare to)
> >> >>>>> or something similar on the succeeding rows.
> >> >>>>>
> >> >>>>> I didn't realize I did not know where it is and I would like to
> >> >>>>> find it.
> >> >>>>>
> >> >>>>> If this makes sense, can anyone tell me how to open this window? I
> >> >>>>> have no way of reconnecting with the instructor for the online
> >> >>>>> class.
> >>
> >>
> >>
>
>
Re: Mail Merge [If...Then...Else...]
sos-DC 6/13/2007 6:18:02 PM
Maybe the same thing I missed.

Do not type { } directly from the keyboard.
Use Ctrl+F9 to create the proper braces

"danhattan" wrote:

[Quoted Text]
> I appreciate the reply, but apparently don't quite understand. In the example
> I posted there are 3 pairs of braces. When I compare my syntax to Graham's
> there doesn't appear to be a difference except that his False conditions
> prints another field whereas mine simply prints nothing.
>
> Again, what am I missing here?
>
> "Peter Jamieson" wrote:
>
> > You have to use ctrl-F9 to enter /every/ pair of the special field code
> > braces. In this case, that's 3 pairs of the braces.
> >
> > Peter Jamieson
> > "danhattan" <hatinonya[ at ]screwthespammers.com> wrote in message
> > news:189BC987-0883-468A-9217-CBD3D0741DEA[ at ]microsoft.com...
> > > Hello. I had a question similar to the original poster and have followed
> > > this
> > > thread to the end. It seems like I know what I'm doing but there must be
> > > something wrong with my syntax as I'm not getting all the results I'd
> > > expect.
> > > My field is constructed like this:
> > > { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }
> > >
> > > The idea is to print the Spouse field if there's data present, and print
> > > nothing if data isn't present.
> > >
> > > If there's nothing in the Spouse field, this works perfectly. The problem
> > > is
> > > that if there is data, rather than printing the field data, the field
> > > result
> > > is {MERGEFIELD Spouse}, i.e. what's literally between the quotation marks.
> > >
> > > My syntax looks right to my eye, but I'm clearly missing something. Any
> > > help
> > > you could lend would be much appreciated. Thank you.
> > >
> > > "Graham Mayor" wrote:
> > >
> > >> The basic setup is
> > >>
> > >> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
> > >>
> > >> however this assumes that the whole address is in one field. If you have
> > >> separate streets for streets, towns etc, test one of the home fields that
> > >> should always be present (such as the town) and put all the fields that
> > >> represent the addresses formatted as you require them between the quotes.
> > >>
> > >> --
> > >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > >> Graham Mayor - Word MVP
> > >>
> > >> My web site www.gmayor.com
> > >> Word MVP web site http://word.mvps.org
> > >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > >>
> > >>
> > >> sos-DC wrote:
> > >> > You're right - it would help if you knew what I was trying to achieve.
> > >> >
> > >> > The data base is in Excel, slightly over 400 entries.
> > >> >
> > >> > There are separate columns for HOME addresses and WORK addresses.
> > >> >
> > >> > Most of the entries have home addresses only, approximately 325.
> > >> >
> > >> > The rest are WORK addresses only or both HOME and WORK addresses
> > >> > provided.
> > >> >
> > >> > What I am trying to do is create a Mail Merge document that will
> > >> > print the home addresses. If the home address column is blank it will
> > >> > automatically go to the work address columns.
> > >> >
> > >> > I have created a great many additional columns (17 columns) into
> > >> > which I entered a great many formulas so that I can use just one
> > >> > merge document for the entire data base. (Haven't tested it yet.)
> > >> >
> > >> > I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> > >> > (MERGE) to handle the problem.
> > >> >
> > >> > I'm comfortable with Excel but the next person to take over the task
> > >> > may not be and the extra columns will definitely confuse them.
> > >> >
> > >> > Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
> > >> > problem.
> > >> >
> > >> >
> > >> > "Graham Mayor" wrote:
> > >> >
> > >> >> The basics of mail merge are covered at
> > >> >> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> > >> >> If you tell us exactly what you are trying to achieve, we will tell
> > >> >> you what is possible.
> > >> >>
> > >> >> --
> > >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > >> >> Graham Mayor - Word MVP
> > >> >>
> > >> >> My web site www.gmayor.com
> > >> >> Word MVP web site http://word.mvps.org
> > >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > >> >>
> > >> >> sos-DC wrote:
> > >> >>> I previously tried that but could not get it to work.
> > >> >>> I did notice that the original field brackets {} hand lines around
> > >> >>> them but the ones I entered did NOT. Could that make a difference?
> > >> >>>
> > >> >>> I checked the link you provided but an unable to find anything. I'm
> > >> >>> not very good at searching the web.
> > >> >>>
> > >> >>> "Graham Mayor" wrote:
> > >> >>>
> > >> >>>> If you are building complex conditional fields, it is better to
> > >> >>>> insert them manually using CTRL+F9 for each set of field brackets
> > >> >>>> {}. The field dialogs are too inflexible. See
> > >> >>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
> > >> >>>> of field construction.
> > >> >>>>
> > >> >>>> --
> > >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > >> >>>> Graham Mayor - Word MVP
> > >> >>>>
> > >> >>>> My web site www.gmayor.com
> > >> >>>> Word MVP web site http://word.mvps.org
> > >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > >> >>>>
> > >> >>>> sos-DC wrote:
> > >> >>>>> Under
> > >> >>>>>
> > >> >>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
> > >> >>>>> bar) is
> > >> >>>>>
> > >> >>>>> If...Then...Else...
> > >> >>>>>
> > >> >>>>> This window allows for adding text under specific circumstances.
> > >> >>>>>
> > >> >>>>> During an online class for Mail Merge, I was shown a similar
> > >> >>>>> window, but instead of inserting text, you would add Mergefields.
> > >> >>>>>
> > >> >>>>> The window had the first row (Field name, Comparison, Compare to)
> > >> >>>>> or something similar on the succeeding rows.
> > >> >>>>>
> > >> >>>>> I didn't realize I did not know where it is and I would like to
> > >> >>>>> find it.
> > >> >>>>>
> > >> >>>>> If this makes sense, can anyone tell me how to open this window? I
> > >> >>>>> have no way of reconnecting with the instructor for the online
> > >> >>>>> class.
> > >>
> > >>
> > >>
> >
> >
Re: Mail Merge [If...Then...Else...]
danhattan 6/13/2007 6:22:01 PM
I'm doing that to start with. Are you saying that each time I need a pair of
braces I need to hit Ctrl+F9 again?

P.S. Thanks for chipping in. Appreciate it.

"sos-DC" wrote:

[Quoted Text]
> Maybe the same thing I missed.
>
> Do not type { } directly from the keyboard.
> Use Ctrl+F9 to create the proper braces
>
> "danhattan" wrote:
>
> > I appreciate the reply, but apparently don't quite understand. In the example
> > I posted there are 3 pairs of braces. When I compare my syntax to Graham's
> > there doesn't appear to be a difference except that his False conditions
> > prints another field whereas mine simply prints nothing.
> >
> > Again, what am I missing here?
> >
> > "Peter Jamieson" wrote:
> >
> > > You have to use ctrl-F9 to enter /every/ pair of the special field code
> > > braces. In this case, that's 3 pairs of the braces.
> > >
> > > Peter Jamieson
> > > "danhattan" <hatinonya[ at ]screwthespammers.com> wrote in message
> > > news:189BC987-0883-468A-9217-CBD3D0741DEA[ at ]microsoft.com...
> > > > Hello. I had a question similar to the original poster and have followed
> > > > this
> > > > thread to the end. It seems like I know what I'm doing but there must be
> > > > something wrong with my syntax as I'm not getting all the results I'd
> > > > expect.
> > > > My field is constructed like this:
> > > > { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }
> > > >
> > > > The idea is to print the Spouse field if there's data present, and print
> > > > nothing if data isn't present.
> > > >
> > > > If there's nothing in the Spouse field, this works perfectly. The problem
> > > > is
> > > > that if there is data, rather than printing the field data, the field
> > > > result
> > > > is {MERGEFIELD Spouse}, i.e. what's literally between the quotation marks.
> > > >
> > > > My syntax looks right to my eye, but I'm clearly missing something. Any
> > > > help
> > > > you could lend would be much appreciated. Thank you.
> > > >
> > > > "Graham Mayor" wrote:
> > > >
> > > >> The basic setup is
> > > >>
> > > >> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
> > > >>
> > > >> however this assumes that the whole address is in one field. If you have
> > > >> separate streets for streets, towns etc, test one of the home fields that
> > > >> should always be present (such as the town) and put all the fields that
> > > >> represent the addresses formatted as you require them between the quotes.
> > > >>
> > > >> --
> > > >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> Graham Mayor - Word MVP
> > > >>
> > > >> My web site www.gmayor.com
> > > >> Word MVP web site http://word.mvps.org
> > > >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >>
> > > >>
> > > >> sos-DC wrote:
> > > >> > You're right - it would help if you knew what I was trying to achieve.
> > > >> >
> > > >> > The data base is in Excel, slightly over 400 entries.
> > > >> >
> > > >> > There are separate columns for HOME addresses and WORK addresses.
> > > >> >
> > > >> > Most of the entries have home addresses only, approximately 325.
> > > >> >
> > > >> > The rest are WORK addresses only or both HOME and WORK addresses
> > > >> > provided.
> > > >> >
> > > >> > What I am trying to do is create a Mail Merge document that will
> > > >> > print the home addresses. If the home address column is blank it will
> > > >> > automatically go to the work address columns.
> > > >> >
> > > >> > I have created a great many additional columns (17 columns) into
> > > >> > which I entered a great many formulas so that I can use just one
> > > >> > merge document for the entire data base. (Haven't tested it yet.)
> > > >> >
> > > >> > I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> > > >> > (MERGE) to handle the problem.
> > > >> >
> > > >> > I'm comfortable with Excel but the next person to take over the task
> > > >> > may not be and the extra columns will definitely confuse them.
> > > >> >
> > > >> > Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
> > > >> > problem.
> > > >> >
> > > >> >
> > > >> > "Graham Mayor" wrote:
> > > >> >
> > > >> >> The basics of mail merge are covered at
> > > >> >> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> > > >> >> If you tell us exactly what you are trying to achieve, we will tell
> > > >> >> you what is possible.
> > > >> >>
> > > >> >> --
> > > >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >> Graham Mayor - Word MVP
> > > >> >>
> > > >> >> My web site www.gmayor.com
> > > >> >> Word MVP web site http://word.mvps.org
> > > >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >>
> > > >> >> sos-DC wrote:
> > > >> >>> I previously tried that but could not get it to work.
> > > >> >>> I did notice that the original field brackets {} hand lines around
> > > >> >>> them but the ones I entered did NOT. Could that make a difference?
> > > >> >>>
> > > >> >>> I checked the link you provided but an unable to find anything. I'm
> > > >> >>> not very good at searching the web.
> > > >> >>>
> > > >> >>> "Graham Mayor" wrote:
> > > >> >>>
> > > >> >>>> If you are building complex conditional fields, it is better to
> > > >> >>>> insert them manually using CTRL+F9 for each set of field brackets
> > > >> >>>> {}. The field dialogs are too inflexible. See
> > > >> >>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
> > > >> >>>> of field construction.
> > > >> >>>>
> > > >> >>>> --
> > > >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >>>> Graham Mayor - Word MVP
> > > >> >>>>
> > > >> >>>> My web site www.gmayor.com
> > > >> >>>> Word MVP web site http://word.mvps.org
> > > >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >>>>
> > > >> >>>> sos-DC wrote:
> > > >> >>>>> Under
> > > >> >>>>>
> > > >> >>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
> > > >> >>>>> bar) is
> > > >> >>>>>
> > > >> >>>>> If...Then...Else...
> > > >> >>>>>
> > > >> >>>>> This window allows for adding text under specific circumstances.
> > > >> >>>>>
> > > >> >>>>> During an online class for Mail Merge, I was shown a similar
> > > >> >>>>> window, but instead of inserting text, you would add Mergefields.
> > > >> >>>>>
> > > >> >>>>> The window had the first row (Field name, Comparison, Compare to)
> > > >> >>>>> or something similar on the succeeding rows.
> > > >> >>>>>
> > > >> >>>>> I didn't realize I did not know where it is and I would like to
> > > >> >>>>> find it.
> > > >> >>>>>
> > > >> >>>>> If this makes sense, can anyone tell me how to open this window? I
> > > >> >>>>> have no way of reconnecting with the instructor for the online
> > > >> >>>>> class.
> > > >>
> > > >>
> > > >>
> > >
> > >
Re: Mail Merge [If...Then...Else...]
danhattan 6/13/2007 6:23:03 PM
Never mind. I didn't read Peter's post as closely as I should have. Guess it
just seems a bit counter-intuitive. Thanks again.

"sos-DC" wrote:

[Quoted Text]
> Maybe the same thing I missed.
>
> Do not type { } directly from the keyboard.
> Use Ctrl+F9 to create the proper braces
>
> "danhattan" wrote:
>
> > I appreciate the reply, but apparently don't quite understand. In the example
> > I posted there are 3 pairs of braces. When I compare my syntax to Graham's
> > there doesn't appear to be a difference except that his False conditions
> > prints another field whereas mine simply prints nothing.
> >
> > Again, what am I missing here?
> >
> > "Peter Jamieson" wrote:
> >
> > > You have to use ctrl-F9 to enter /every/ pair of the special field code
> > > braces. In this case, that's 3 pairs of the braces.
> > >
> > > Peter Jamieson
> > > "danhattan" <hatinonya[ at ]screwthespammers.com> wrote in message
> > > news:189BC987-0883-468A-9217-CBD3D0741DEA[ at ]microsoft.com...
> > > > Hello. I had a question similar to the original poster and have followed
> > > > this
> > > > thread to the end. It seems like I know what I'm doing but there must be
> > > > something wrong with my syntax as I'm not getting all the results I'd
> > > > expect.
> > > > My field is constructed like this:
> > > > { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }
> > > >
> > > > The idea is to print the Spouse field if there's data present, and print
> > > > nothing if data isn't present.
> > > >
> > > > If there's nothing in the Spouse field, this works perfectly. The problem
> > > > is
> > > > that if there is data, rather than printing the field data, the field
> > > > result
> > > > is {MERGEFIELD Spouse}, i.e. what's literally between the quotation marks.
> > > >
> > > > My syntax looks right to my eye, but I'm clearly missing something. Any
> > > > help
> > > > you could lend would be much appreciated. Thank you.
> > > >
> > > > "Graham Mayor" wrote:
> > > >
> > > >> The basic setup is
> > > >>
> > > >> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield Word}"}
> > > >>
> > > >> however this assumes that the whole address is in one field. If you have
> > > >> separate streets for streets, towns etc, test one of the home fields that
> > > >> should always be present (such as the town) and put all the fields that
> > > >> represent the addresses formatted as you require them between the quotes.
> > > >>
> > > >> --
> > > >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> Graham Mayor - Word MVP
> > > >>
> > > >> My web site www.gmayor.com
> > > >> Word MVP web site http://word.mvps.org
> > > >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >>
> > > >>
> > > >> sos-DC wrote:
> > > >> > You're right - it would help if you knew what I was trying to achieve.
> > > >> >
> > > >> > The data base is in Excel, slightly over 400 entries.
> > > >> >
> > > >> > There are separate columns for HOME addresses and WORK addresses.
> > > >> >
> > > >> > Most of the entries have home addresses only, approximately 325.
> > > >> >
> > > >> > The rest are WORK addresses only or both HOME and WORK addresses
> > > >> > provided.
> > > >> >
> > > >> > What I am trying to do is create a Mail Merge document that will
> > > >> > print the home addresses. If the home address column is blank it will
> > > >> > automatically go to the work address columns.
> > > >> >
> > > >> > I have created a great many additional columns (17 columns) into
> > > >> > which I entered a great many formulas so that I can use just one
> > > >> > merge document for the entire data base. (Haven't tested it yet.)
> > > >> >
> > > >> > I am hoping to find a simple way to use IF...THEN...ELSE... in Word
> > > >> > (MERGE) to handle the problem.
> > > >> >
> > > >> > I'm comfortable with Excel but the next person to take over the task
> > > >> > may not be and the extra columns will definitely confuse them.
> > > >> >
> > > >> > Is it possible to use IF...THEN... ELSE... in Word (Merge) to solve my
> > > >> > problem.
> > > >> >
> > > >> >
> > > >> > "Graham Mayor" wrote:
> > > >> >
> > > >> >> The basics of mail merge are covered at
> > > >> >> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> > > >> >> If you tell us exactly what you are trying to achieve, we will tell
> > > >> >> you what is possible.
> > > >> >>
> > > >> >> --
> > > >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >> Graham Mayor - Word MVP
> > > >> >>
> > > >> >> My web site www.gmayor.com
> > > >> >> Word MVP web site http://word.mvps.org
> > > >> >> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >>
> > > >> >> sos-DC wrote:
> > > >> >>> I previously tried that but could not get it to work.
> > > >> >>> I did notice that the original field brackets {} hand lines around
> > > >> >>> them but the ones I entered did NOT. Could that make a difference?
> > > >> >>>
> > > >> >>> I checked the link you provided but an unable to find anything. I'm
> > > >> >>> not very good at searching the web.
> > > >> >>>
> > > >> >>> "Graham Mayor" wrote:
> > > >> >>>
> > > >> >>>> If you are building complex conditional fields, it is better to
> > > >> >>>> insert them manually using CTRL+F9 for each set of field brackets
> > > >> >>>> {}. The field dialogs are too inflexible. See
> > > >> >>>> http://www.gmayor.com/formatting_word_fields.htm for some examples
> > > >> >>>> of field construction.
> > > >> >>>>
> > > >> >>>> --
> > > >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >>>> Graham Mayor - Word MVP
> > > >> >>>>
> > > >> >>>> My web site www.gmayor.com
> > > >> >>>> Word MVP web site http://word.mvps.org
> > > >> >>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> > > >> >>>>
> > > >> >>>> sos-DC wrote:
> > > >> >>>>> Under
> > > >> >>>>>
> > > >> >>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge tool
> > > >> >>>>> bar) is
> > > >> >>>>>
> > > >> >>>>> If...Then...Else...
> > > >> >>>>>
> > > >> >>>>> This window allows for adding text under specific circumstances.
> > > >> >>>>>
> > > >> >>>>> During an online class for Mail Merge, I was shown a similar
> > > >> >>>>> window, but instead of inserting text, you would add Mergefields.
> > > >> >>>>>
> > > >> >>>>> The window had the first row (Field name, Comparison, Compare to)
> > > >> >>>>> or something similar on the succeeding rows.
> > > >> >>>>>
> > > >> >>>>> I didn't realize I did not know where it is and I would like to
> > > >> >>>>> find it.
> > > >> >>>>>
> > > >> >>>>> If this makes sense, can anyone tell me how to open this window? I
> > > >> >>>>> have no way of reconnecting with the instructor for the online
> > > >> >>>>> class.
> > > >>
> > > >>
> > > >>
> > >
> > >
Re: Mail Merge [If...Then...Else...]
"Graham Mayor" <gmayor[ at ]REMOVETHISmvps.org> 6/14/2007 6:12:45 AM
Exactly! These are fields not brackets. CTRL+F9 inserts a field marker.
Incidentally you don't need the second set of quotes in this example
{ IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }"}
would work

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>

danhattan wrote:
[Quoted Text]
> I'm doing that to start with. Are you saying that each time I need a
> pair of braces I need to hit Ctrl+F9 again?
>
> P.S. Thanks for chipping in. Appreciate it.
>
> "sos-DC" wrote:
>
>> Maybe the same thing I missed.
>>
>> Do not type { } directly from the keyboard.
>> Use Ctrl+F9 to create the proper braces
>>
>> "danhattan" wrote:
>>
>>> I appreciate the reply, but apparently don't quite understand. In
>>> the example I posted there are 3 pairs of braces. When I compare my
>>> syntax to Graham's there doesn't appear to be a difference except
>>> that his False conditions prints another field whereas mine simply
>>> prints nothing.
>>>
>>> Again, what am I missing here?
>>>
>>> "Peter Jamieson" wrote:
>>>
>>>> You have to use ctrl-F9 to enter /every/ pair of the special field
>>>> code braces. In this case, that's 3 pairs of the braces.
>>>>
>>>> Peter Jamieson
>>>> "danhattan" <hatinonya[ at ]screwthespammers.com> wrote in message
>>>> news:189BC987-0883-468A-9217-CBD3D0741DEA[ at ]microsoft.com...
>>>>> Hello. I had a question similar to the original poster and have
>>>>> followed this
>>>>> thread to the end. It seems like I know what I'm doing but there
>>>>> must be something wrong with my syntax as I'm not getting all the
>>>>> results I'd expect.
>>>>> My field is constructed like this:
>>>>> { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }
>>>>>
>>>>> The idea is to print the Spouse field if there's data present,
>>>>> and print nothing if data isn't present.
>>>>>
>>>>> If there's nothing in the Spouse field, this works perfectly. The
>>>>> problem is
>>>>> that if there is data, rather than printing the field data, the
>>>>> field result
>>>>> is {MERGEFIELD Spouse}, i.e. what's literally between the
>>>>> quotation marks.
>>>>>
>>>>> My syntax looks right to my eye, but I'm clearly missing
>>>>> something. Any help
>>>>> you could lend would be much appreciated. Thank you.
>>>>>
>>>>> "Graham Mayor" wrote:
>>>>>
>>>>>> The basic setup is
>>>>>>
>>>>>> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield
>>>>>> Word}"}
>>>>>>
>>>>>> however this assumes that the whole address is in one field. If
>>>>>> you have separate streets for streets, towns etc, test one of
>>>>>> the home fields that should always be present (such as the town)
>>>>>> and put all the fields that represent the addresses formatted as
>>>>>> you require them between the quotes.
>>>>>>
>>>>>> --
>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>> Graham Mayor - Word MVP
>>>>>>
>>>>>> My web site www.gmayor.com
>>>>>> Word MVP web site http://word.mvps.org
>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>
>>>>>>
>>>>>> sos-DC wrote:
>>>>>>> You're right - it would help if you knew what I was trying to
>>>>>>> achieve.
>>>>>>>
>>>>>>> The data base is in Excel, slightly over 400 entries.
>>>>>>>
>>>>>>> There are separate columns for HOME addresses and WORK
>>>>>>> addresses.
>>>>>>>
>>>>>>> Most of the entries have home addresses only, approximately 325.
>>>>>>>
>>>>>>> The rest are WORK addresses only or both HOME and WORK addresses
>>>>>>> provided.
>>>>>>>
>>>>>>> What I am trying to do is create a Mail Merge document that will
>>>>>>> print the home addresses. If the home address column is blank
>>>>>>> it will automatically go to the work address columns.
>>>>>>>
>>>>>>> I have created a great many additional columns (17 columns) into
>>>>>>> which I entered a great many formulas so that I can use just one
>>>>>>> merge document for the entire data base. (Haven't tested it
>>>>>>> yet.)
>>>>>>>
>>>>>>> I am hoping to find a simple way to use IF...THEN...ELSE... in
>>>>>>> Word (MERGE) to handle the problem.
>>>>>>>
>>>>>>> I'm comfortable with Excel but the next person to take over the
>>>>>>> task may not be and the extra columns will definitely confuse
>>>>>>> them.
>>>>>>>
>>>>>>> Is it possible to use IF...THEN... ELSE... in Word (Merge) to
>>>>>>> solve my problem.
>>>>>>>
>>>>>>>
>>>>>>> "Graham Mayor" wrote:
>>>>>>>
>>>>>>>> The basics of mail merge are covered at
>>>>>>>> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
>>>>>>>> If you tell us exactly what you are trying to achieve, we will
>>>>>>>> tell you what is possible.
>>>>>>>>
>>>>>>>> --
>>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>>> Graham Mayor - Word MVP
>>>>>>>>
>>>>>>>> My web site www.gmayor.com
>>>>>>>> Word MVP web site http://word.mvps.org
>>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>>>
>>>>>>>> sos-DC wrote:
>>>>>>>>> I previously tried that but could not get it to work.
>>>>>>>>> I did notice that the original field brackets {} hand lines
>>>>>>>>> around them but the ones I entered did NOT. Could that make a
>>>>>>>>> difference?
>>>>>>>>>
>>>>>>>>> I checked the link you provided but an unable to find
>>>>>>>>> anything. I'm not very good at searching the web.
>>>>>>>>>
>>>>>>>>> "Graham Mayor" wrote:
>>>>>>>>>
>>>>>>>>>> If you are building complex conditional fields, it is better
>>>>>>>>>> to insert them manually using CTRL+F9 for each set of field
>>>>>>>>>> brackets {}. The field dialogs are too inflexible. See
>>>>>>>>>> http://www.gmayor.com/formatting_word_fields.htm for some
>>>>>>>>>> examples of field construction.
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>>>>> Graham Mayor - Word MVP
>>>>>>>>>>
>>>>>>>>>> My web site www.gmayor.com
>>>>>>>>>> Word MVP web site http://word.mvps.org
>>>>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>>>>>>>>>>
>>>>>>>>>> sos-DC wrote:
>>>>>>>>>>> Under
>>>>>>>>>>>
>>>>>>>>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge
>>>>>>>>>>> tool bar) is
>>>>>>>>>>>
>>>>>>>>>>> If...Then...Else...
>>>>>>>>>>>
>>>>>>>>>>> This window allows for adding text under specific
>>>>>>>>>>> circumstances.
>>>>>>>>>>>
>>>>>>>>>>> During an online class for Mail Merge, I was shown a similar
>>>>>>>>>>> window, but instead of inserting text, you would add
>>>>>>>>>>> Mergefields.
>>>>>>>>>>>
>>>>>>>>>>> The window had the first row (Field name, Comparison,
>>>>>>>>>>> Compare to) or something similar on the succeeding rows.
>>>>>>>>>>>
>>>>>>>>>>> I didn't realize I did not know where it is and I would
>>>>>>>>>>> like to find it.
>>>>>>>>>>>
>>>>>>>>>>> If this makes sense, can anyone tell me how to open this
>>>>>>>>>>> window? I have no way of reconnecting with the instructor
>>>>>>>>>>> for the online class.


Re: Mail Merge [If...Then...Else...]
danhattan 6/14/2007 5:26:02 PM
Thank you very, very much! Also, linked to your document in your first reply
and have already happily learned about the F9 key. I was just closing and
re-opening the document.

Hope life on Cyprus is grand!

"Graham Mayor" wrote:

[Quoted Text]
> Exactly! These are fields not brackets. CTRL+F9 inserts a field marker.
> Incidentally you don't need the second set of quotes in this example
> { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }"}
> would work
>
> --
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> Graham Mayor - Word MVP
>
> My web site www.gmayor.com
> Word MVP web site http://word.mvps.org
> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
>
> danhattan wrote:
> > I'm doing that to start with. Are you saying that each time I need a
> > pair of braces I need to hit Ctrl+F9 again?
> >
> > P.S. Thanks for chipping in. Appreciate it.
> >
> > "sos-DC" wrote:
> >
> >> Maybe the same thing I missed.
> >>
> >> Do not type { } directly from the keyboard.
> >> Use Ctrl+F9 to create the proper braces
> >>
> >> "danhattan" wrote:
> >>
> >>> I appreciate the reply, but apparently don't quite understand. In
> >>> the example I posted there are 3 pairs of braces. When I compare my
> >>> syntax to Graham's there doesn't appear to be a difference except
> >>> that his False conditions prints another field whereas mine simply
> >>> prints nothing.
> >>>
> >>> Again, what am I missing here?
> >>>
> >>> "Peter Jamieson" wrote:
> >>>
> >>>> You have to use ctrl-F9 to enter /every/ pair of the special field
> >>>> code braces. In this case, that's 3 pairs of the braces.
> >>>>
> >>>> Peter Jamieson
> >>>> "danhattan" <hatinonya[ at ]screwthespammers.com> wrote in message
> >>>> news:189BC987-0883-468A-9217-CBD3D0741DEA[ at ]microsoft.com...
> >>>>> Hello. I had a question similar to the original poster and have
> >>>>> followed this
> >>>>> thread to the end. It seems like I know what I'm doing but there
> >>>>> must be something wrong with my syntax as I'm not getting all the
> >>>>> results I'd expect.
> >>>>> My field is constructed like this:
> >>>>> { IF {MERGEFIELD Spouse }<> "" "{ MERGEFIELD Spouse }" "" }
> >>>>>
> >>>>> The idea is to print the Spouse field if there's data present,
> >>>>> and print nothing if data isn't present.
> >>>>>
> >>>>> If there's nothing in the Spouse field, this works perfectly. The
> >>>>> problem is
> >>>>> that if there is data, rather than printing the field data, the
> >>>>> field result
> >>>>> is {MERGEFIELD Spouse}, i.e. what's literally between the
> >>>>> quotation marks.
> >>>>>
> >>>>> My syntax looks right to my eye, but I'm clearly missing
> >>>>> something. Any help
> >>>>> you could lend would be much appreciated. Thank you.
> >>>>>
> >>>>> "Graham Mayor" wrote:
> >>>>>
> >>>>>> The basic setup is
> >>>>>>
> >>>>>> {IF {Mergefield Home} <> "" "{Mergefield Home}" "{Mergefield
> >>>>>> Word}"}
> >>>>>>
> >>>>>> however this assumes that the whole address is in one field. If
> >>>>>> you have separate streets for streets, towns etc, test one of
> >>>>>> the home fields that should always be present (such as the town)
> >>>>>> and put all the fields that represent the addresses formatted as
> >>>>>> you require them between the quotes.
> >>>>>>
> >>>>>> --
> >>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>> Graham Mayor - Word MVP
> >>>>>>
> >>>>>> My web site www.gmayor.com
> >>>>>> Word MVP web site http://word.mvps.org
> >>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>>
> >>>>>>
> >>>>>> sos-DC wrote:
> >>>>>>> You're right - it would help if you knew what I was trying to
> >>>>>>> achieve.
> >>>>>>>
> >>>>>>> The data base is in Excel, slightly over 400 entries.
> >>>>>>>
> >>>>>>> There are separate columns for HOME addresses and WORK
> >>>>>>> addresses.
> >>>>>>>
> >>>>>>> Most of the entries have home addresses only, approximately 325.
> >>>>>>>
> >>>>>>> The rest are WORK addresses only or both HOME and WORK addresses
> >>>>>>> provided.
> >>>>>>>
> >>>>>>> What I am trying to do is create a Mail Merge document that will
> >>>>>>> print the home addresses. If the home address column is blank
> >>>>>>> it will automatically go to the work address columns.
> >>>>>>>
> >>>>>>> I have created a great many additional columns (17 columns) into
> >>>>>>> which I entered a great many formulas so that I can use just one
> >>>>>>> merge document for the entire data base. (Haven't tested it
> >>>>>>> yet.)
> >>>>>>>
> >>>>>>> I am hoping to find a simple way to use IF...THEN...ELSE... in
> >>>>>>> Word (MERGE) to handle the problem.
> >>>>>>>
> >>>>>>> I'm comfortable with Excel but the next person to take over the
> >>>>>>> task may not be and the extra columns will definitely confuse
> >>>>>>> them.
> >>>>>>>
> >>>>>>> Is it possible to use IF...THEN... ELSE... in Word (Merge) to
> >>>>>>> solve my problem.
> >>>>>>>
> >>>>>>>
> >>>>>>> "Graham Mayor" wrote:
> >>>>>>>
> >>>>>>>> The basics of mail merge are covered at
> >>>>>>>> http://www.gmayor.com/mail_merge_labels_with_word_xp.htm
> >>>>>>>> If you tell us exactly what you are trying to achieve, we will
> >>>>>>>> tell you what is possible.
> >>>>>>>>
> >>>>>>>> --
> >>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>>>> Graham Mayor - Word MVP
> >>>>>>>>
> >>>>>>>> My web site www.gmayor.com
> >>>>>>>> Word MVP web site http://word.mvps.org
> >>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>>>>
> >>>>>>>> sos-DC wrote:
> >>>>>>>>> I previously tried that but could not get it to work.
> >>>>>>>>> I did notice that the original field brackets {} hand lines
> >>>>>>>>> around them but the ones I entered did NOT. Could that make a
> >>>>>>>>> difference?
> >>>>>>>>>
> >>>>>>>>> I checked the link you provided but an unable to find
> >>>>>>>>> anything. I'm not very good at searching the web.
> >>>>>>>>>
> >>>>>>>>> "Graham Mayor" wrote:
> >>>>>>>>>
> >>>>>>>>>> If you are building complex conditional fields, it is better
> >>>>>>>>>> to insert them manually using CTRL+F9 for each set of field
> >>>>>>>>>> brackets {}. The field dialogs are too inflexible. See
> >>>>>>>>>> http://www.gmayor.com/formatting_word_fields.htm for some
> >>>>>>>>>> examples of field construction.
> >>>>>>>>>>
> >>>>>>>>>> --
> >>>>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>>>>>> Graham Mayor - Word MVP
> >>>>>>>>>>
> >>>>>>>>>> My web site www.gmayor.com
> >>>>>>>>>> Word MVP web site http://word.mvps.org
> >>>>>>>>>> <>>< ><<> ><<> <>>< ><<> <>>< <>><<>
> >>>>>>>>>>
> >>>>>>>>>> sos-DC wrote:
> >>>>>>>>>>> Under
> >>>>>>>>>>>
> >>>>>>>>>>> Tools > Letters > Mail Merge >Insert Word Field (in merge
> >>>>>>>>>>> tool bar) is
> >>>>>>>>>>>
> >>>>>>>>>>> If...Then...Else...
> >>>>>>>>>>>
> >>>>>>>>>>> This window allows for adding text under specific
> >>>>>>>>>>> circumstances.
> >>>>>>>>>>>
> >>>>>>>>>>> During an online class for Mail Merge, I was shown a similar
> >>>>>>>>>>> window, but instead of inserting text, you would add
> >>>>>>>>>>> Mergefields.
> >>>>>>>>>>>
> >>>>>>>>>>> The window had the first row (Field name, Comparison,
> >>>>>>>>>>> Compare to) or something similar on the succeeding rows.
> >>>>>>>>>>>
> >>>>>>>>>>> I didn't realize I did not know where it is and I would
> >>>>>>>>>>> like to find it.
> >>>>>>>>>>>
> >>>>>>>>>>> If this makes sense, can anyone tell me how to open this
> >>>>>>>>>>> window? I have no way of reconnecting with the instructor
> >>>>>>>>>>> for the online class.
>
>
>
Re: Mail Merge [If...Then...Else...]
"Graham Mayor" <gmayor[ at ]REMOVETHISmvps.org> 6/15/2007 5:48:09 AM
danhattan wrote:
[Quoted Text]
> Hope life on Cyprus is grand!

It has its moments - but water shortages are going to be a problem this
summer :(

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>


Home | Search | Terms | Imprint Contact
Newsgroups Reader - provided by WiredBox.Net