Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 34
Default add OR to already nested If function - help required

Hi
I have a formula I use 5 times but I want to nest them into one formula but
I cannot get anywhere.

The formulas are

=IF(AND((C3<=F2),(D3F2)),"on","off")
=IF(AND((C4<=F2),(D4F2)),"on","off")
=IF(AND((C5<=F2),(D5F2)),"on","off")
=IF(AND((C6<=F2),(D6F2)),"on","off")
=IF(AND((C7<=F2),(D7F2)),"on","off")

By calling the functions A, B,C etc a phonetic description would be

if A or B or C or D or E is true then put "on" otherwise put "off"

Can anyone nest this for me as I have spent a day and got nowhere.

TIA

Kenny


  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 268
Default add OR to already nested If function - help required

Not having ctual figures to work on, I'm not sure this is what you want , but
worth a try:
=IF(OR(AND((C3<=F2),(D3F2)),AND((C4<=F2),(D4F2)) ,AND((C5<=F2),(D5F2)),AND((C6<=F2),(D6F2)),AND(( C7<=F2),(D7F2))),"on","off")
Of course, all in one formula, no line breaks or spaces.

"N E Body" wrote:

Hi
I have a formula I use 5 times but I want to nest them into one formula but
I cannot get anywhere.

The formulas are

=IF(AND((C3<=F2),(D3F2)),"on","off")
=IF(AND((C4<=F2),(D4F2)),"on","off")
=IF(AND((C5<=F2),(D5F2)),"on","off")
=IF(AND((C6<=F2),(D6F2)),"on","off")
=IF(AND((C7<=F2),(D7F2)),"on","off")

By calling the functions A, B,C etc a phonetic description would be

if A or B or C or D or E is true then put "on" otherwise put "off"

Can anyone nest this for me as I have spent a day and got nowhere.

TIA

Kenny



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 34
Default add OR to already nested If function - help required

Many thanks kassie, I have tested it and it works exactly as I wanted.

Kind Regards
Kenny


"kassie" wrote in message
...
Not having ctual figures to work on, I'm not sure this is what you want ,
but
worth a try:
=IF(OR(AND((C3<=F2),(D3F2)),AND((C4<=F2),(D4F2)) ,AND((C5<=F2),(D5F2)),AND((C6<=F2),(D6F2)),AND(( C7<=F2),(D7F2))),"on","off")
Of course, all in one formula, no line breaks or spaces.

"N E Body" wrote:

Hi
I have a formula I use 5 times but I want to nest them into one formula
but
I cannot get anywhere.

The formulas are

=IF(AND((C3<=F2),(D3F2)),"on","off")
=IF(AND((C4<=F2),(D4F2)),"on","off")
=IF(AND((C5<=F2),(D5F2)),"on","off")
=IF(AND((C6<=F2),(D6F2)),"on","off")
=IF(AND((C7<=F2),(D7F2)),"on","off")

By calling the functions A, B,C etc a phonetic description would be

if A or B or C or D or E is true then put "on" otherwise put "off"

Can anyone nest this for me as I have spent a day and got nowhere.

TIA

Kenny





  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default add OR to already nested If function - help required

Try this with fewer key strokes

=IF(AND(C3:C7<=F2,D3:D7=F2),"on","off")
It's an array formula, you have to comit with Ctrl+Shift+Enter (not just
enter)



"N E Body" wrote:

Hi
I have a formula I use 5 times but I want to nest them into one formula but
I cannot get anywhere.

The formulas are

=IF(AND((C3<=F2),(D3F2)),"on","off")
=IF(AND((C4<=F2),(D4F2)),"on","off")
=IF(AND((C5<=F2),(D5F2)),"on","off")
=IF(AND((C6<=F2),(D6F2)),"on","off")
=IF(AND((C7<=F2),(D7F2)),"on","off")

By calling the functions A, B,C etc a phonetic description would be

if A or B or C or D or E is true then put "on" otherwise put "off"

Can anyone nest this for me as I have spent a day and got nowhere.

TIA

Kenny



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
Help required with COUNTIF/AND function DAT Excel Worksheet Functions 3 August 3rd 06 07:38 PM
Nested If function? stillgreen Excel Worksheet Functions 5 February 20th 06 01:39 PM
Round a number in nested function kim Excel Worksheet Functions 1 July 6th 05 11:45 AM
Countif Function -Nested Angi Excel Discussion (Misc queries) 7 May 4th 05 07:04 PM
clock Wildman Excel Worksheet Functions 2 April 26th 05 10:31 AM


All times are GMT +1. The time now is 04:37 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"