Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
On Mon, 11 Aug 2008 23:00:03 -0700, Geo wrote:
I want the difference between the Resigned date and Joining date; if I use the formula B1-A1, I get the correct answer in the General number format. But if I use the date format it is showing one month in excess. Eg: A B C 28/05/1996 12/08/2008 =16/03/12 (B1-A1) B1-A1 will give you 4459 as answer in General number format which is correct, whereas date format will give you 16/03/12 as answer which is one month excess. Hope this clarifiaction is quite ok. please help.... -- Geo If all you want is a particular format, then the formula I supplied earlier, with dates in C6:D6 =TEXT(DATEDIF(C6,D6,"md"),"00")&"/"& TEXT(DATEDIF(C6,D6,"ym"),"00")&"/"& TEXT(DATEDIF(C6,D6,"y"),"00") already gave you the result in the format you wanted. You felt that was unsatisfactory, but you haven't responded to any of the comments that were made to explain why it was unsatisfactory. You indicated you got some large number when you tried to use it in a formula, but you did not tell us how you got that number. Using the above dates, it gives a result of 15/02/12 12 years 2 months 15 days This is a text string, not a numeric value. I hope you are aware that you cannot specify any exact time interval that includes years and months, without further rules. Neither a "year" nor a "month" are an exact interval. A year can be 365 or 366 days. A "month" can be 28, 29, 30 or 31 days. If you are computing something that depends on days in service, use the number of days in you calculations and not this text string. --ron |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do I calculate exact difference between two dates in y,m,d. | Excel Worksheet Functions | |||
How do I calculate exact difference between two dates in y,m,d. | Excel Worksheet Functions | |||
How do I calculate the difference between 2 dates (m,d,y) ? | Excel Worksheet Functions | |||
Calculate Difference b/e 2 dates. | New Users to Excel | |||
Calculate difference between two dates | Excel Worksheet Functions |