ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Complex If/Then (https://www.excelbanter.com/excel-worksheet-functions/238768-complex-if-then.html)

PAL

Complex If/Then
 
Can someone help on this formula? Basically, trying to get a "Yes", if the
field, E2, equals, "Open" or "Closed" or "Close Out" or, "Completed".

Perhaps there is an easier way.

=IF(E2="Open","Yes",(IF(E2="Closed","Yes",IF(E2="C lose Out","Yes","",
IF(E2="Completed","Yes","")))

Thanks.

Pete_UK

Complex If/Then
 
Here's one way:

=IF(ISNA(MATCH(E2,{"Open","Closed","Close out","Completed"},
0)),"","Yes")

Hope this helps.

Pete


On Aug 3, 3:50*pm, PAL wrote:
Can someone help on this formula? *Basically, trying to get a "Yes", if the
field, E2, equals, "Open" or "Closed" or "Close Out" or, "Completed".

Perhaps there is an easier way.

=IF(E2="Open","Yes",(IF(E2="Closed","Yes",IF(E2="C lose Out","Yes","",
IF(E2="Completed","Yes","")))

Thanks.



David Biddulph[_2_]

Complex If/Then
 
You were probably trying to say
=IF(E2="Open","Yes",IF(E2="Closed","Yes",IF(E2="Cl ose Out","Yes",
IF(E2="Completed","Yes",""))))

An alternative is
=IF(OR(E2={"Open","Closed","Close Out","Completed"}),"Yes","")
--
David Biddulph

"PAL" wrote in message
...
Can someone help on this formula? Basically, trying to get a "Yes", if
the
field, E2, equals, "Open" or "Closed" or "Close Out" or, "Completed".

Perhaps there is an easier way.

=IF(E2="Open","Yes",(IF(E2="Closed","Yes",IF(E2="C lose Out","Yes","",
IF(E2="Completed","Yes","")))

Thanks.





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

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com