Home |
Search |
Today's Posts |
#4
![]() |
|||
|
|||
![]()
Hi,
Is there a way to put Gord formula into a VBA function and say name it YrsMthsDays whereby the formula would be =YrsMthsDays(A1,A2) Thanks, Rob "Gord Dibben" <gorddibbATshawDOTca wrote in message ... Mike Your result would be 9 years and 23 days which Excel rounds to 9 years and 1 month. What would you like to have displayed? 9 years and 23/31 months? This formula will give you 9 years, 0 months, 23 days =DATEDIF(A1,A2,"y") &" years, "& DATEDIF(A1,A2,"ym")&" months, "& DATEDIF(A1,A2,"md") & " days" Where A1 holds earliest date. Gord Dibben Excel MVP On Sat, 27 Nov 2004 10:19:02 -0800, "Mike New" <Mike wrote: I am trying to calculate chronological age - years and complete months - for school report purposes. I can get Years and months but not accurately - say for a date of birth 22nd November 1995 and a date of the 15th December - I get 9 years and 1 month. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Creating GIFs in Excel 2003 for use in Dreamweaver | Charts and Charting in Excel | |||
Charting Data from Excel | Charts and Charting in Excel | |||
How does Excel 2003 calculate trendlines with respect to axes? | Charts and Charting in Excel | |||
how do i calculate a chart gradient in excel? | Charts and Charting in Excel | |||
Staring Excel Problem | Excel Discussion (Misc queries) |