Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Is it possible to use wildcards in an IF function to test a text string in a
cell. I have a cell that could contain 2 text string options "300 Denier Polyester" or "600 Denier Polyester" Because the operators who input this text may write it in different ways (300 Denier Polyester or Polyester 300 Denier) I would like to write an IF function in another cell that tests the cell in question for whether the string contains 300 or 600 and depending on the result, perform a different calculation |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Something for you to experiment with:
=IF(ISNUMBER(FIND("300",A1)),"X","Y") best wishes -- Bernard V Liengme Microsoft Excel MVP www.stfx.ca/people/bliengme remove caps from email "Chacky" wrote in message ... Is it possible to use wildcards in an IF function to test a text string in a cell. I have a cell that could contain 2 text string options "300 Denier Polyester" or "600 Denier Polyester" Because the operators who input this text may write it in different ways (300 Denier Polyester or Polyester 300 Denier) I would like to write an IF function in another cell that tests the cell in question for whether the string contains 300 or 600 and depending on the result, perform a different calculation |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
try:
=IF(ISNUMBER(SEARCH("300",A1)),"300 Found",IF(ISNUMBER(SEARCH("600",A1)),"600 Found","Neither found")) "Chacky" wrote: Is it possible to use wildcards in an IF function to test a text string in a cell. I have a cell that could contain 2 text string options "300 Denier Polyester" or "600 Denier Polyester" Because the operators who input this text may write it in different ways (300 Denier Polyester or Polyester 300 Denier) I would like to write an IF function in another cell that tests the cell in question for whether the string contains 300 or 600 and depending on the result, perform a different calculation |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
You can use Find for case insensitive searches like this....
=IF(ISNUMBER(FIND(300,A2)),"Yes","No") If you need case sensitivity, then you would use the SEARCH function instead. Rick "Chacky" wrote in message ... Is it possible to use wildcards in an IF function to test a text string in a cell. I have a cell that could contain 2 text string options "300 Denier Polyester" or "600 Denier Polyester" Because the operators who input this text may write it in different ways (300 Denier Polyester or Polyester 300 Denier) I would like to write an IF function in another cell that tests the cell in question for whether the string contains 300 or 600 and depending on the result, perform a different calculation |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Thought it was the other way round ? <g
FIND is case sensitive while SEARCH is not -- Max Singapore http://savefile.com/projects/236895 xdemechanik --- "Rick Rothstein (MVP - VB)" wrote: You can use Find for case insensitive searches like this.... =IF(ISNUMBER(FIND(300,A2)),"Yes","No") If you need case sensitivity, then you would use the SEARCH function instead. Rick |
#6
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
LOL... I think my mind wandered there a little bit, huh? What I was talking
about when I **started** me response was the fact that values such as 300, where there was no case to worry about, work fine with the FIND function... and then I have no idea what happened to my response by the time I finished it. And I can't even use "it was a long response" to explain it either (that was one of my shorter responses). Thanks for catching that. Rick "Max" wrote in message ... Thought it was the other way round ? <g FIND is case sensitive while SEARCH is not -- Max Singapore http://savefile.com/projects/236895 xdemechanik --- "Rick Rothstein (MVP - VB)" wrote: You can use Find for case insensitive searches like this.... =IF(ISNUMBER(FIND(300,A2)),"Yes","No") If you need case sensitivity, then you would use the SEARCH function instead. Rick |
#7
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
As Max has pointed out elsewhere, FIND is a case **sensitive** function
whereas SEARCH is not. What I was trying to say, before I screwed my response up royally, is that you can use FIND for this case because you are looking for a value (300) which does not have upper/lower case issues. Rick "Rick Rothstein (MVP - VB)" wrote in message ... You can use Find for case insensitive searches like this.... =IF(ISNUMBER(FIND(300,A2)),"Yes","No") If you need case sensitivity, then you would use the SEARCH function instead. Rick "Chacky" wrote in message ... Is it possible to use wildcards in an IF function to test a text string in a cell. I have a cell that could contain 2 text string options "300 Denier Polyester" or "600 Denier Polyester" Because the operators who input this text may write it in different ways (300 Denier Polyester or Polyester 300 Denier) I would like to write an IF function in another cell that tests the cell in question for whether the string contains 300 or 600 and depending on the result, perform a different calculation |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Wildcards and if | Excel Worksheet Functions | |||
Wildcards in SUMIF Function | Excel Worksheet Functions | |||
Wildcards in RTD | Excel Discussion (Misc queries) | |||
Can wildcards be used in the Logic Test of an Excel "IF" function? | Excel Worksheet Functions | |||
Problems with SUMIF function and Wildcards (* and ?) | Excel Worksheet Functions |