Can "COUNT" and/or "COUNTIF" look at dates?

D

DA

I am trying to count the number of issues opened during a
specific week. The formula is on one worksheet, the date
is on the "abc" sheet and the issues are on the "xyz"
sheet.

Can the Count function actually count "dates" or can it
just count numbers?

Here is my formula that is not working. I know the answer
should be 5 and it is returning 0.

=COUNTIF(xyz!D9:D43,"<=abc!$R$1""and">=abc!$R$2)

Thanks!
 
A

A.W.J. Ales

DA,

Countif can only cope with one condition and you are using two conditions.
Use
=SUMPRODUCT(--(xyz!D9:D43<=abc!$R$1)*(xyz!D9:D43>=abc!$R$2))

By the way : As far as Excel is concerned Dates *are* just numbers. Excel
is counting day from 1-1-1900 (1) and further.

--
Regards,
Auk Ales

* Please reply to this newsgroup only *
* I will not react on unsolicited e-mails *
 
F

Frank Kabel

Hi
try (if R1 and R2 are dates as well as the range D9:D43)
=SUMPRODUCT((xyz!D9:D43<=abc!$R$1)*(xyz!D9:D43>=abc!$R$2))
 
D

DA

This worked...THANKS! I should have asked first and not
wasted 2 hours trying to figure it out myself! :)
 

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