ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Character (https://www.excelbanter.com/excel-worksheet-functions/166053-character.html)

tjh

Character
 
Hello,

I would like cell B1 to reference cell A1, and if cell A1 contains a "N"
within the cells text (multiple characters) then I would like cell B1 to give
a particular phrase otherwise give other text.

Thanks,

Philip J Smith

Character
 
Hi tjh

Use the =FIND function nested within an =IF function.

Your check within the IF function should look for an #N/A return from the
FIND function.

Excel's help or textbooks should explain these well.

Regards

Phil

"tjh" wrote:

Hello,

I would like cell B1 to reference cell A1, and if cell A1 contains a "N"
within the cells text (multiple characters) then I would like cell B1 to give
a particular phrase otherwise give other text.

Thanks,


Bob Phillips

Character
 
=IF(ISNUMBER(SEARCH("N",A1)),"phrase 1","phrase2 ")

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"tjh" wrote in message
...
Hello,

I would like cell B1 to reference cell A1, and if cell A1 contains a "N"
within the cells text (multiple characters) then I would like cell B1 to
give
a particular phrase otherwise give other text.

Thanks,




Dave Peterson

Character
 
=if(countif(a1,"*N*")0,"it's there","it's not there")
or
=if(isnumber(search("n",a1)),"it's there","it's not there")
or
=if(isnumber(Find("N",a1)),"it's there","it's not there")

=find() is case sensitive.
=search() is not case sensitive.
The =countif() is not case sensitive, too.

tjh wrote:

Hello,

I would like cell B1 to reference cell A1, and if cell A1 contains a "N"
within the cells text (multiple characters) then I would like cell B1 to give
a particular phrase otherwise give other text.

Thanks,


--

Dave Peterson

tjh

Character
 
Is this what you mean? I get a Value error with this. Not sure what I am
doing wrong.
=IF(ISNA(FIND("N",A1)),"NO N",FIND("N",A1))

Thanks,


"Philip J Smith" wrote:

Hi tjh

Use the =FIND function nested within an =IF function.

Your check within the IF function should look for an #N/A return from the
FIND function.

Excel's help or textbooks should explain these well.

Regards

Phil

"tjh" wrote:

Hello,

I would like cell B1 to reference cell A1, and if cell A1 contains a "N"
within the cells text (multiple characters) then I would like cell B1 to give
a particular phrase otherwise give other text.

Thanks,


Philip J Smith

Character
 
Apologies I should have suggested checking for #Value! rather than #N/A!

=IF(ISERR(FIND("N",UPPER(A1))),"No N","N")

I've also added UPPER, this will find "n" and "N".

Regards

Phil


"tjh" wrote:

Is this what you mean? I get a Value error with this. Not sure what I am
doing wrong.
=IF(ISNA(FIND("N",A1)),"NO N",FIND("N",A1))

Thanks,


"Philip J Smith" wrote:

Hi tjh

Use the =FIND function nested within an =IF function.

Your check within the IF function should look for an #N/A return from the
FIND function.

Excel's help or textbooks should explain these well.

Regards

Phil

"tjh" wrote:

Hello,

I would like cell B1 to reference cell A1, and if cell A1 contains a "N"
within the cells text (multiple characters) then I would like cell B1 to give
a particular phrase otherwise give other text.

Thanks,



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

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