counting specific figures in cells dependant upon contents of adjacent cells

  • Thread starter Thread starter judoist
  • Start date Start date
J

judoist

I have 3 columns. The first has single digits (0-9), the second ha
various numbers with x's and blank spaces in between, and the third ha
a 0,1 or 2 in it.

I am able to count the numer of blanks in column 2 every time a
appears in column 1 by using formula below...

=SUMPRODUCT(($A1:$F350=5)*($B1:$B350="X"))

... I'd like to introduce column 3 so that if a 0 is present, the "x
is not counted. If a 1 is present "x" is counted once and 2, "x" i
counted twice.

Any suggestions
 
Sorry ...

Meant ofcourse to say i am able to count the number of "x"s in column
using formula, not blanks
 
Hi

I think your formula must have been posted wrongly. I reckon it should have
been:
=SUMPRODUCT(($A1:$A350=5)*($B1:$B350="X"))

To include the next column in the way you describe try this:
=SUMPRODUCT(($A1:$A350=5)*($B1:$B350="X")*($C1:$C350))

Hope this helps
 
Back
Top