compute count of range of date fields with a given year

  • Thread starter Thread starter Excel formula
  • Start date Start date
E

Excel formula

I would like to count the number of date cells in a range with a specific
year. For instance, I would like to do

COUNTIF(cell range, year(current cell) = 2007)
 
Hi,

Try this:

=SUMPRODUCT(--(YEAR(A1:A100)=2007))

or something like this array formula

=SUM(IF(YEAR(A5:A18)=2007,1))
enter using Ctrl+Shift+Enter

Regards!
Jean-Guy
 
Back
Top