ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Vary response IF certain text is contained in a cell (https://www.excelbanter.com/excel-worksheet-functions/245408-vary-response-if-certain-text-contained-cell.html)

Colin Hayes

Vary response IF certain text is contained in a cell
 

Hi All

I need a formula which says this :

If the text 'AB' is contained anywhere in E2 , put 'Yes'. If not put
'No'.

Can someone help with this?



Best Wishes




Atishoo

Vary response IF certain text is contained in a cell
 

=IF(ISERROR(FIND("ab",E2,1)),"No","Yes")


"Colin Hayes" wrote:


Hi All

I need a formula which says this :

If the text 'AB' is contained anywhere in E2 , put 'Yes'. If not put
'No'.

Can someone help with this?



Best Wishes





Colin Hayes

Vary response IF certain text is contained in a cell
 
In article , Atishoo
writes

=IF(ISERROR(FIND("ab",E2,1)),"No","Yes")


Hi

OK Thanks for getting back.

I'm trying to incorporate the first part of the code above into my
existing formula :

=IF(D2<=20,J2,IF(J2=2,6,IF(OR(J2=1,J2=11),5,J2)))


Instead of saying 'if D2 is greater or equal to 20' , I need to say 'If
E2 contains AB'.


The 'Yes' and 'No' replies from above would not be needed therefore.

I keep getting errors. Can you advise?


Thanks again.

Best Wishes




"Colin Hayes" wrote:


Hi All

I need a formula which says this :

If the text 'AB' is contained anywhere in E2 , put 'Yes'. If not put
'No'.

Can someone help with this?



Best Wishes






Ashish Mathur[_2_]

Vary response IF certain text is contained in a cell
 
Hi

=IF(isnumber(search("ab",E2,1)),J2,IF(J2=2,6,IF(OR (J2=1,J2=11),5,J2)))

--
Regards,

Ashish Mathur
Microsoft Excel MVP
www.ashishmathur.com

"Colin Hayes" wrote in message
...
In article , Atishoo
writes

=IF(ISERROR(FIND("ab",E2,1)),"No","Yes")


Hi

OK Thanks for getting back.

I'm trying to incorporate the first part of the code above into my
existing formula :

=IF(D2<=20,J2,IF(J2=2,6,IF(OR(J2=1,J2=11),5,J2)))


Instead of saying 'if D2 is greater or equal to 20' , I need to say 'If E2
contains AB'.


The 'Yes' and 'No' replies from above would not be needed therefore.

I keep getting errors. Can you advise?


Thanks again.

Best Wishes




"Colin Hayes" wrote:


Hi All

I need a formula which says this :

If the text 'AB' is contained anywhere in E2 , put 'Yes'. If not put
'No'.

Can someone help with this?



Best Wishes







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

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