#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Count Between dates

How can I count between two dates when format for the dates is DD-MM-YY

I need to know how many days are between 21/04/09 and 28/04/09

The solution should be 8 if I use =(A2-A1+1) but Im getting #VALUE!

Im used format = Custom = dd/mm/yy, also General and Number but they are
not working either.

Any suggestions?

--
Juan Carlos
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Count Between dates

That is because your values are text strings rather than dates. Convert them
to dates first.
--
Gary''s Student - gsnu200904


"juancarlos" wrote:

How can I count between two dates when format for the dates is DD-MM-YY

I need to know how many days are between 21/04/09 and 28/04/09

The solution should be 8 if I use =(A2-A1+1) but Im getting #VALUE!

Im used format = Custom = dd/mm/yy, also General and Number but they are
not working either.

Any suggestions?

--
Juan Carlos

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 17
Default Count Between dates

Gary,
I converted them to dates but I got the same result.

Juan

"Gary''s Student" wrote:

That is because your values are text strings rather than dates. Convert them
to dates first.
--
Gary''s Student - gsnu200904


"juancarlos" wrote:

How can I count between two dates when format for the dates is DD-MM-YY

I need to know how many days are between 21/04/09 and 28/04/09

The solution should be 8 if I use =(A2-A1+1) but Im getting #VALUE!

Im used format = Custom = dd/mm/yy, also General and Number but they are
not working either.

Any suggestions?

--
Juan Carlos

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default Count Between dates

If you are getting a #VALUE! error I'd be willing to bet that you haven't
changed them from text to dates.
If they are dates, =ISNUMBER(A1) and =ISNUMBER(A2) will return TRUE, and
=ISTEXT(A1) and =ISTEXT(A2) will return FALSE.
Perhaps you'd care to tell us what those formulae do return?
--
David Biddulph

"Juan Carlos" wrote in message
...
Gary,
I converted them to dates but I got the same result.

Juan

"Gary''s Student" wrote:

That is because your values are text strings rather than dates. Convert
them
to dates first.
--
Gary''s Student - gsnu200904


"juancarlos" wrote:

How can I count between two dates when format for the dates is DD-MM-YY

I need to know how many days are between 21/04/09 and 28/04/09

The solution should be 8 if I use =(A2-A1+1) but I'm getting #VALUE!

I'm used format = Custom = dd/mm/yy, also General and Number but they
are
not working either.

Any suggestions?

--
Juan Carlos



  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 17
Default Count Between dates

David,
Im getting false for =ISNUMBER(A1)(A2) and True for =ISTEXT(A1)(A2). I
think my problem have to do with how the dates are entered. I dont think
that excel recognized the format dd/mm/yy to calculate number of days between
dates.

Im going to convert the A1 and A2 to dates by adding 2 more columns using
the following formula =DATE(RIGHT(D60,2)+2000,MID(D60,4,2),LEFT(D60,2)) and
then will do the calculation from there.

Unless you have another solution for me

Juan



Juan

"David Biddulph" wrote:

If you are getting a #VALUE! error I'd be willing to bet that you haven't
changed them from text to dates.
If they are dates, =ISNUMBER(A1) and =ISNUMBER(A2) will return TRUE, and
=ISTEXT(A1) and =ISTEXT(A2) will return FALSE.
Perhaps you'd care to tell us what those formulae do return?
--
David Biddulph

"Juan Carlos" wrote in message
...
Gary,
I converted them to dates but I got the same result.

Juan

"Gary''s Student" wrote:

That is because your values are text strings rather than dates. Convert
them
to dates first.
--
Gary''s Student - gsnu200904


"juancarlos" wrote:

How can I count between two dates when format for the dates is DD-MM-YY

I need to know how many days are between 21/04/09 and 28/04/09

The solution should be 8 if I use =(A2-A1+1) but I'm getting #VALUE!

I'm used format = Custom = dd/mm/yy, also General and Number but they
are
not working either.

Any suggestions?

--
Juan Carlos






  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,389
Default Count Between dates

Excel has no trouble recognizing dd/mm/yy as a date. It doesn't require 4
digits for the year.

If you entered the date, then the likely problem is that your cell was
formatted as text beforehand.

Try this:
1. Format the cell as a date
2. Re-enter the date.

Now try your formula.

Regards,
Fred

"Juan Carlos" wrote in message
...
David,
Im getting false for =ISNUMBER(A1)(A2) and True for =ISTEXT(A1)(A2). I
think my problem have to do with how the dates are entered. I dont think
that excel recognized the format dd/mm/yy to calculate number of days
between
dates.

Im going to convert the A1 and A2 to dates by adding 2 more columns using
the following formula =DATE(RIGHT(D60,2)+2000,MID(D60,4,2),LEFT(D60,2))
and
then will do the calculation from there.

Unless you have another solution for me

Juan



Juan

"David Biddulph" wrote:

If you are getting a #VALUE! error I'd be willing to bet that you haven't
changed them from text to dates.
If they are dates, =ISNUMBER(A1) and =ISNUMBER(A2) will return TRUE, and
=ISTEXT(A1) and =ISTEXT(A2) will return FALSE.
Perhaps you'd care to tell us what those formulae do return?
--
David Biddulph

"Juan Carlos" wrote in message
...
Gary,
I converted them to dates but I got the same result.

Juan

"Gary''s Student" wrote:

That is because your values are text strings rather than dates.
Convert
them
to dates first.
--
Gary''s Student - gsnu200904


"juancarlos" wrote:

How can I count between two dates when format for the dates is
DD-MM-YY

I need to know how many days are between 21/04/09 and 28/04/09

The solution should be 8 if I use =(A2-A1+1) but I'm getting #VALUE!

I'm used format = Custom = dd/mm/yy, also General and Number but
they
are
not working either.

Any suggestions?

--
Juan Carlos





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Count Dates between Dates exclude Text Ken Excel Discussion (Misc queries) 3 April 8th 09 07:59 PM
Count Dates Matthew Tyrus Excel Discussion (Misc queries) 2 October 16th 08 06:29 PM
I want to count the total Number of dates between two dates How? seshu Excel Worksheet Functions 3 February 7th 08 05:41 PM
Count Dates? msnews.microsoft.com[_3_] Excel Worksheet Functions 3 February 1st 08 05:22 PM
need to convert list of dates to count no. of dates by week neowok Excel Worksheet Functions 13 January 30th 06 03:54 PM


All times are GMT +1. The time now is 02:02 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"