adding dates with excel

  • Thread starter Thread starter Justin
  • Start date Start date
J

Justin

I just want to be able to count days between two dates. I am using excel 2003.

example
a1 12/5/1999 b1 03/04/2007
if i want the number of days between a1 and b1 in c1, what should the
formula read? What format should each of the cells be in?
 
since you are concerned about days
=b1-a1 will work

I find that datedif is more efficient when dealing with months or years....
 
So far none of these have worked.

Brad said:
since you are concerned about days
=b1-a1 will work

I find that datedif is more efficient when dealing with months or years....
 
That's too bad, Justin. Any chance you could tell us what "not working"
means? Do you get an error? Do you get 0? Do you get a result that doesn't
look right?

Your date format doesn't matter. What does matter is that your cells need to
contain valid Excel dates. Lots of times people have text masquerading as
dates. This causes problems because you can't do calculations on text. Try
to following:

=istext(a1)

If it returns True, then you have text, not dates, and that's your problem.

Regards,
Fred.
 
Which suggest you do not have real dates in the cells. What happens if you
type (in any blank cell) =B1+1 ? Do you see B1' s date incremented by one
(ie the next day?
best wishes
 
Thanks Fred and Bernard. My dates are text and not excel dates. Is there a
way to change the text to date. This is the form they are in the cells
03/24/1975 (mm,dd,yyyy)

Justin
 
Text to columns is the simplest way to replace the text with dates.
Highlight your column and use:

Data>Text to Columns>Next>Next>Date>MDY>Finish

Regards,
Fred.
 
From your original post, put this formula in c1:

=ABS(VALUE(A1)-VALUE(B1))

and format c1 as general. It will return 2646 which is the number of
days between the two dates.

Clioff Edwards
 
Back
Top