Re: if statements, searching for commma

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



=if(isnumber(search(",",a1)),"flag","unflag")

or

=if(countif(a1,"*,*")>0,"flag","unflag")

spirosu wrote:

Does anyone know if there is a way to use the if function to search for
comma's within a cell. For instance, in the below, using the if
function, I've tried the below without success.

if(A1=",","Flag","Unflag")

It's obviously wrong...I'd greatly appreciate if someone can lend me a
hand. Seems simple enough but can't figure it out.

_Column_A__
Row 1 EMERGING MARKETS
Row 2 KINNUNEN, JUHA
Row 3 POSEN, DAVID
Row 4 HORTON, WILLIAM

--
spirosu
------------------------------------------------------------------------
spirosu's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=7442
View this thread: http://www.excelforum.com/showthread.php?threadid=513762

--

Dave Peterson
.



Relevant Pages

  • if statements, searching for commma
    ... comma's within a cell. ... Row 4 HORTON, WILLIAM ... spirosu's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=7442 ...
    (microsoft.public.excel.misc)
  • macro to copy and paste into another workbook
    ... example) to another workbook. ... over 15 users each with their own spreadsheet that will have one cell ... spirosu's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=7442 ...
    (microsoft.public.excel.misc)
  • Re: Hey, quick question
    ... You may want to look up "About cell and range references" in excel's help. ... Sundeep's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=35110 ... Dave Peterson ...
    (microsoft.public.excel)
  • Re: Copy Formula That References Another Sheet
    ... Dave Peterson Wrote: ... select your range of formulas (more than one cell) ... edit replace ... JR573PUTT's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=31587 ...
    (microsoft.public.excel.misc)
  • Re: Text in formula bar but not the cell
    ... Any chance you could just select that cell ... Rickula2's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=34027 ... Dave Peterson ...
    (microsoft.public.excel.misc)