Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
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
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
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
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
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
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
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
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
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
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
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 |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Count Dates between Dates exclude Text | Excel Discussion (Misc queries) | |||
Count Dates | Excel Discussion (Misc queries) | |||
I want to count the total Number of dates between two dates How? | Excel Worksheet Functions | |||
Count Dates? | Excel Worksheet Functions | |||
need to convert list of dates to count no. of dates by week | Excel Worksheet Functions |