Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default Nesting conditional statements

You've contradicted yourself. If A1 is neither 1 nor 2 nor 4, do you want
the answer to be 6 or 4 or 3?
--
David Biddulph

GARY wrote:
I need to test the contents of cell a1 for three values:

If a1 = 1 then 5, else 6
If a1 = 2 then 9, else 4
if a1 = 4 then 10, else 3

How do I nest the conditional statements?



  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default Nesting conditional statements

No. You are still contradicting yourself. Please look again at what you
have written and think about what you have said.

In what condition does the 6 apply?
In what condition does the 4 apply?
In what condition does the 3 apply?
And hence in what condition does the 7 apply?
--
David Biddulph

"gcotterl" wrote in message
...
Is these better:

If a1 = 1 then 5, else 6
If a1 = 2 then 9, else 4
if a1 = 4 then 10, else 3
if a1 is not 1 or 2 or 4 then 7



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default Nesting conditional statements

Look in Excel help for the IF function.
--
David Biddulph

gcotterl wrote:
Hi David,

I can write one formula that tests one condition.
I can write several separate formulas each testing one condition.
But, apparently, I can't correctly "nest" several separate into one
statement.

Can you help me? (Ignore my examples and use decent examples).

Gary



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nesting 7 statements Eden397 Excel Discussion (Misc queries) 2 June 5th 08 07:14 PM
Workaround for nesting more than 7 statements campka Excel Discussion (Misc queries) 2 August 15th 06 02:39 PM
Nesting IF statements [email protected] Excel Discussion (Misc queries) 2 March 7th 06 07:43 AM
Nesting IF statements, Conditional Formatting Nick Danger Excel Discussion (Misc queries) 2 September 26th 05 10:31 PM
nesting if statements tjb Excel Worksheet Functions 4 September 9th 05 11:43 PM


All times are GMT +1. The time now is 04:28 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"