Conditional Counting of Arrays

R

rbrychckn

I have a worksheet that has the following structure:

A B C


In Column B is a unique ID for the row (4-digit number). In C i
either an "X" or a blank as a yes/no column.

I want to count the number of X's in Column C only if they have an I
in Column B. I've used the COUNTIF function with an IF statement bu
it's giving me #NUM/#VALUE errors. Any help would be great.

{=COUNTIF((IF(ISBLANK(B:B),(C:C))),"X")
 
E

Eric

This should do the trick. However, this only works if the
cells you don't want to count are truly blanks. If they
have spaces or zeroes, this will not work correctly.

=SUMPRODUCT((B1:B25<>"")*(C1:C25="X"))

(Expand the ranges as necessary)

Eric
 
R

rbrychckn

thanks to the both of you. This is the 3rd time SUMPRODUCT has been th
answer to my question--I should really learn how to use it.

- To
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top