Average with Date Criteria Error

D

diaare

Could someone please help me figure out why the following formula is
producing a #value error?

=AVERAGE(IF((YEAR(AC9:AC74)=2008),AD9:AD74))

I entered it as an array as well.

Thanks,

Diane
 
D

Dave Peterson

Do you have non-dates (or non-numeric) data in ac9:ac74?

If you have strings you can't change, maybe:

=AVERAGE(IF(text(AC9:AC74,"yyyy")="2008",AD9:AD74))
 
P

pdberger

Diarre --
A different approach. If you've got dates in the AC column, then this
formula will work. Remember it's an 'array' or CSE formula, which means that
after you enter it you need to press Ctrl-Shift-Enter rather than just Enter.
It will appear {surrounded by curly brackets}.

=AVERAGE(IF(YEAR(A1:A10)=2008,B1:B10))

Just substitute my A&B ranges for your AC & AD ranges.

HTH
 
Top