Results 1 to 4 of 4

Search column of data to find if cells contain a comma?

This is a discussion on Search column of data to find if cells contain a comma? within the Excel Questions forums, part of the Question Forums category; Can anyone help me please? Iím trying to find a way to search a column of data within Excel to ...

  1. #1
    New Member
    Join Date
    Jun 2011
    Posts
    9

    Default Search column of data to find if cells contain a comma?

    Can anyone help me please?
    Iím trying to find a way to search a column of data within Excel to detect if a comma exists anywhere within the range to cells?
    Idea being A1 is True or False (or other flag value) if range B2:B500 contains a ď,Ē
    The comma could be anywhere within any cell within the range. Example of cells within the range:
    Dog
    Cat
    Bunny
    ,
    Dog,
    Cat, Dog
    Etc

    I donít explicitly need to count the number of times a comma is found, although that would be cool, I just need to be able to flag if a comma exists.

    Many thanks in advance

  2. #2
    Board Regular T. Valko's Avatar
    Join Date
    May 2009
    Location
    Pittsburgh
    Posts
    16,133

    Default Re: Search column of data to find if cells contain a comma?

    Quote Originally Posted by ExcelHound View Post
    Can anyone help me please?
    I’m trying to find a way to search a column of data within Excel to detect if a comma exists anywhere within the range to cells?
    Idea being A1 is True or False (or other flag value) if range B2:B500 contains a “,”
    The comma could be anywhere within any cell within the range. Example of cells within the range:
    Dog
    Cat
    Bunny
    ,
    Dog,
    Cat, Dog
    Etc

    I don’t explicitly need to count the number of times a comma is found, although that would be cool, I just need to be able to flag if a comma exists.

    Many thanks in advance
    Try this...

    =COUNTIF(B2:B500,"*,*")>0

    =COUNTIF(B2:B500,"*,*")
    .
    Biff
    Microsoft MVP - Excel

    Using Excel 2002, 2007
    KISS - Keep It Simple Stupid

  3. #3
    New Member
    Join Date
    Jun 2011
    Posts
    9

    Default Re: Search column of data to find if cells contain a comma?

    Thanks, you da man!!! works like a cham.

  4. #4
    Board Regular T. Valko's Avatar
    Join Date
    May 2009
    Location
    Pittsburgh
    Posts
    16,133

    Default Re: Search column of data to find if cells contain a comma?

    Quote Originally Posted by ExcelHound View Post
    Thanks, you da man!!! works like a cham.
    You're welcome. Thanks for the feedback!
    .
    Biff
    Microsoft MVP - Excel

    Using Excel 2002, 2007
    KISS - Keep It Simple Stupid

Tags for this Thread

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


DMCA.com