formula needed for counting months

S

Shocked

the formula that I ended up with seems to work was:
=sumproduct(--(month(a1:a100)=1,--year(a1:a100)=2004))

this formula did not count blanks for whatever reason.

Thanks agai
 
M

Max

Shocked said:
the formula that I ended up with seems to work was:
=sumproduct(--(month(a1:a100)=1,--year(a1:a100)=2004))

this formula did not count blanks for whatever reason.

Thanks for posting back

Think the saving grace was the 2nd condition in your:
=SUMPRODUCT(--(MONTH(A1:A100)=1),--(YEAR(A1:A100)=2004))
which resolves to an array of zeros for blank cells
 

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