A Microsoft Word forum. Microsoft Office Word Forum - WordBanter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Microsoft Office Word Forum - WordBanter forum » Microsoft Word Newsgroups » Mailmerge
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

IF / AND option?



 
 
Thread Tools Display Modes
  #1  
Old April 12th 06, 05:14 PM posted to microsoft.public.word.mailmerge.fields
external usenet poster
 
Posts: n/a
Default IF / AND option?

is there a way to return text based on two fields.

IF field 1 = a
AND field 2 = 1
THEN result = x

IF field 1 = a
AND field 2 = 2
THEN result = y

IF field 1 = a
AND field 2 = 3
THEN result = z

IF field 1 = b
THEN result = BLANK

Is this possible.

Ads
  #2  
Old April 12th 06, 05:37 PM posted to microsoft.public.word.mailmerge.fields
external usenet poster
 
Posts: n/a
Default IF / AND option?

Yes it is possible with nested conditional fields.


{ IF { F1 } = "A"{ IF { F2 }="1""X"{ IF { F2 } = "2" "Y"{ IF { F2 } =
"3" "Z"""}}}}

  #3  
Old April 12th 06, 05:47 PM posted to microsoft.public.word.mailmerge.fields
external usenet poster
 
Posts: n/a
Default IF / AND option?

before I start all this I am looking to at a total of 30 different responses.
Can I next that many?

"Greg" wrote:

Yes it is possible with nested conditional fields.


{ IF { F1 } = "A"{ IF { F2 }="1""X"{ IF { F2 } = "2" "Y"{ IF { F2 } =
"3" "Z"""}}}}


  #4  
Old April 12th 06, 07:56 PM posted to microsoft.public.word.mailmerge.fields
external usenet poster
 
Posts: n/a
Default IF / AND option?

I would suggest that data manipulation such as this is best done in the data
source. I am not sure of the exact limit on nested fields, but you may be
getting near it with the 30 different responses.

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

"jermsalerms79" wrote in message
...
before I start all this I am looking to at a total of 30 different
responses.
Can I next that many?

"Greg" wrote:

Yes it is possible with nested conditional fields.


{ IF { F1 } = "A"{ IF { F2 }="1""X"{ IF { F2 } = "2" "Y"{ IF { F2 } =
"3" "Z"""}}}}




  #5  
Old April 13th 06, 06:24 AM posted to microsoft.public.word.mailmerge.fields
external usenet poster
 
Posts: n/a
Default IF / AND option?

See the example at http://www.gmayor.com/formatting_word_fields.htm

--

Graham Mayor - Word MVP

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


jermsalerms79 wrote:
before I start all this I am looking to at a total of 30 different
responses. Can I next that many?

"Greg" wrote:

Yes it is possible with nested conditional fields.


{ IF { F1 } = "A"{ IF { F2 }="1""X"{ IF { F2 } = "2" "Y"{ IF { F2 } =
"3" "Z"""}}}}



  #6  
Old April 14th 06, 04:16 AM posted to microsoft.public.word.mailmerge.fields
external usenet poster
 
Posts: n/a
Default IF / AND option?

Hi jermsalerms79,

You can nest a maximum of 20 IF tests in Word. However, you don't
necessarily have to nest that many to get the desired result. If you post
back more details of what you're working with and what you're trying to
achieve, alternative ways of catering for your 30 combinations can probably
be found.

Cheers


"jermsalerms79" wrote in message
...
is there a way to return text based on two fields.

IF field 1 = a
AND field 2 = 1
THEN result = x

IF field 1 = a
AND field 2 = 2
THEN result = y

IF field 1 = a
AND field 2 = 3
THEN result = z

IF field 1 = b
THEN result = BLANK

Is this possible.



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
No 'Save as' Option in Word 2003 Matt Keefe Microsoft Word Help 8 March 6th 06 05:35 PM
How do I save information from option buttons like other form data ReneeCMC Microsoft Word Help 0 July 19th 05 02:41 PM
how to group option buttons in word? Gallant Microsoft Word Help 1 June 28th 05 03:02 PM
Word Template and Macros (as an option on toolbar) Khan Microsoft Word Help 1 June 2nd 05 05:22 AM
option send to e-mail address (as attachment) unavailable NotAnExpert Microsoft Word Help 1 April 20th 05 03:36 PM


All times are GMT +1. The time now is 01:01 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.
Copyright 2004-2021 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.