count dates in excel

G

Guest

I am trying to count the days between 2 dates. Start date 01/01/01 and End
date 01/05/01 should return 5. However the Datediff function will return 4
because it doesn't count the start date. Adding "+1" to the Datediff function
does not work for me because when the cells with the start and end date are
empty the cell with the Datediff function must be empty.
 
B

Bob Phillips

=IF(OR(A1="",A2=""),"",A1-A2+1)

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
G

Guest

Somehow I read your post as referring to a list of dates. Perhaps I should
read what's actually there instead. Sorry about that.

tj
 
G

Guest

CLR said:
=IF(OR(A1="",B1=""),"",(B1-A1)+1)

Vaya con Dios,
Chuck, CABGx3




Thank you all so much. It works and you probably think "Of Course".
I would have never been able to figure it out without your help.

skchth
 
C

CLR

You're welcome, and thanks for the feedback. And, BTW, today one of us
helps you with something we can, and tomorrow you help someone else with
something you can.........the World gets better with each
experience..........

Vaya con Dios,
Chuck, CABGx3
 

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

Similar Threads


Top