Add cells from a range based on 2 conditions from 2 other ranges

K

Kelly

Hi,
I am trying to add cells from a column based on two conditions.
For example:
the chart below is on one worksheet and on another I am consolidating the
info.
What I want to see if how many types of Black there are with a forecast >0.
Answer should be 3, it should count the 4 without $ owned.
So the two conditions are "Black" and ">0", then add the cells together that
meet those two conditions from the 2nd column.

Types $ owned
Black 3 1500
Black 4 0

Can anyone help?
Kelly
 
G

Guest

Hi

Try something like:
=SUMPRODUCT(--(A2:A50="Black")*(C2:C50>0),(B2:B50))

Hope this helps - or is a guide, at least!
Andy.
 
K

Kelly

Thanks! Worked perfectly :)

Andy said:
Hi

Try something like:
=SUMPRODUCT(--(A2:A50="Black")*(C2:C50>0),(B2:B50))

Hope this helps - or is a guide, at least!
Andy.
 
Top