+ Reply to Thread
Results 1 to 3 of 3

Count if based on what cell starts with

  1. #1
    Registered User
    Join Date
    03-05-2011
    Location
    Savannah, GA
    MS-Off Ver
    Excel 2003 (work), 2010 (home)
    Posts
    44

    Count if based on what cell starts with

    I want to know the count of cells that start with "A" in column A
    I want to know the count of cells that have a value but does not start with "A" in column A

    Would like to know how to do this with a Helper column and without, if it is possible?

    See worksheet for more data


    Thanks,
    Staci
    Attached Files Attached Files

  2. #2
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: Count if based on what cell starts with

    You can use "wildcards" with COUNTIF so to count those starting with "A" try

    =COUNTIF(A2:A100,"A*")

    for non-empty cells that don't begin with "A" you can use SUMPRODUCT, i.e.

    =SUMPRODUCT((LEFT(A2:A100)<>"A")*(A2:A100<>""))

    for a helper column try this formula in B2 copied down

    =IF(LEFT(A2)="A","Red",IF(A1<>"","Blue",""))
    Last edited by daddylonglegs; 03-25-2011 at 09:03 PM.
    Audere est facere

  3. #3
    Registered User
    Join Date
    03-05-2011
    Location
    Savannah, GA
    MS-Off Ver
    Excel 2003 (work), 2010 (home)
    Posts
    44

    Re: Count if based on what cell starts with

    Quote Originally Posted by daddylonglegs View Post
    =IF(LEFT(A2)="A","Red",IF(A1<>"","Blue",""))
    thinking you meant to say:
    Please Login or Register  to view this content.
    here...

    -thanks spidey everything seems to work

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1