Formula Question

J

JohnD

=IF(Info!$B$5:$B$502="May",COUNTIF(Info!$L$5:$L$500,">=15"),"0")
Why doesn't this formula work. Information is being pulled from an Access97
database into 'Info' worksheet. This information is then being analysed in
another worksheet using this formula in one of the cells, but it doesn't
recognise anything labelled 'May' seems count everything. Seperate cells for
other months.
 
D

Don Guillett

You might consider this. Notice 500 for both instead of 502 and 500

=sumproduct((Info!$B$5:$B$500="May")*(Info!$L$5:$L$500>=15))

if you are looking at real dates in col B instead of text for the months
=sumproduct((month(Info!$B$5:$B$500)=5)*(Info!$L$5:$L$500>=15))
 
G

Gary''s Student

Do you want countif to function if
ALL of B5:B502 are May
or
ANY of B5:B502 are May
??
 
S

Stefi

Hi John,

One possible reason in case of imported data that Excel doesn't treat them
as text, not even if they are formatted as text. Try convert Info!B column
with the TEXT function!

Regards,
Stefi


„JohnD†ezt írta:
 
J

JohnD

Brilliant, works a treat.

Cheers Don.

Don Guillett said:
You might consider this. Notice 500 for both instead of 502 and 500

=sumproduct((Info!$B$5:$B$500="May")*(Info!$L$5:$L$500>=15))

if you are looking at real dates in col B instead of text for the months
=sumproduct((month(Info!$B$5:$B$500)=5)*(Info!$L$5:$L$500>=15))
 
Top