+ Reply to Thread
Results 1 to 5 of 5

COUNTIF help

  1. #1
    Registered User
    Join Date
    03-12-2013
    Location
    Atlanta
    MS-Off Ver
    Excel 2003
    Posts
    2

    COUNTIF help

    I have a formula that I just cannot get to work.

    I want to count the number of "yes" in column B.......IF column A is not null

    A B
    x YES
    y YES
    c NO
    (BLANK) YES
    d NO
    e YES
    ui NO

    Should return a value of 3


    Thanks!!!!

  2. #2
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: COUNTIF help

    Try

    =SUMPRODUCT((A1:A10<>"")*(B1:B10="yes"))
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  3. #3
    Forum Expert Kevin UK's Avatar
    Join Date
    12-07-2010
    Location
    Radstock, Somerset
    MS-Off Ver
    365
    Posts
    1,922

    Re: COUNTIF help

    Hi allcarfan

    Try the following:

    =SUMPRODUCT(--(A1:A8<>"="),--(B1:B8="YES"))
    Regards Kevin


    Merged Cells (They are the work of the devil!!!)

  4. #4
    Valued Forum Contributor
    Join Date
    04-03-2012
    Location
    East Sussex, UK
    MS-Off Ver
    Excel 2003:2010
    Posts
    893

    Re: COUNTIF help

    You would need SUMIFS as you have two conditions. For that you would need Excel 2007 or later.

    In Excel 2003 you can use =SUMPRODUCT((A1:A10<>"")*(B1:B10="Yes"))
    Last edited by Spencer101; 03-12-2013 at 12:42 PM.
    If I've been of help, please hit the star

  5. #5
    Registered User
    Join Date
    03-12-2013
    Location
    Atlanta
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: COUNTIF help

    son of a gun...I just needed an asterick! Thanks!

+ 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