Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default formula to see if cell contains one of two text values

I am interested in writing a formula that will check to
see if a cell contains one of two words, and then will
return a value.

So, for example:

=IF(ISNUMBER("textA" or "textB"),"yes","no")

I know this formula isnt exactly correct. Can you help?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default formula to see if cell contains one of two text values

Hi
one way:
=IF(OR(COUNTIF(A1,{"*textA*","*textB*"})),"yes","n o")

--
Regards
Frank Kabel
Frankfurt, Germany

"
schrieb im Newsbeitrag
...
I am interested in writing a formula that will check to
see if a cell contains one of two words, and then will
return a value.

So, for example:

=IF(ISNUMBER("textA" or "textB"),"yes","no")

I know this formula isnt exactly correct. Can you help?


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,089
Default formula to see if cell contains one of two text values

Brian

if you wanted to test cell A1, use:

=IF(OR(A1="textA", A1="textB"),"yes","no")

Regards

Trevor


"
wrote in message ...
I am interested in writing a formula that will check to
see if a cell contains one of two words, and then will
return a value.

So, for example:

=IF(ISNUMBER("textA" or "textB"),"yes","no")

I know this formula isnt exactly correct. Can you help?



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
I want a formula to ignore text values in cell references Russellrupert New Users to Excel 3 January 11th 12 10:15 PM
How do I sum cells that have values from a text formula? DigESource Excel Worksheet Functions 4 April 7th 10 12:19 PM
ignoring text data in a cell when summing values in the same cell FM New Users to Excel 2 February 24th 10 02:51 AM
formula with text values Combo Excel Discussion (Misc queries) 3 April 3rd 08 03:16 PM
Build excel formula using field values as text in the formula val kilbane Excel Worksheet Functions 2 April 18th 07 01:52 PM


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