Thread: countif
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Elkar
 
Posts: n/a
Default countif

Try this:

=SUMPRODUCT(--(MOD(ROW(A1:A10),2)<0),--(A1:A10=1))

This will count only odd numbered rows in the range A1 thru A10 that have a
value of 1.

HTH
Elkar

"FHE" wrote:

I would like to use the CountIf statement but applied to a set of separated
cells, rather then a range.

like countif((a1;a3;a5;a7);1).

However I get a 'value' error on this.

Anythoughts?