Age+Calculator+and+DateDif+Formula

I found this information to be very helpful for me when assigned the task of calculating anniversary dates and longevity pay for all of the employees; the payroll clerk was manually calculating the information. I retrieved the formula from [|www.advanced-excel.com]; they have quite a few helpful tips.

The DATEDIF formula!
DATEDIF represents "date difference" in short. It has 3 parts, the first part is the earlier date, 2nd part is the later date and the 3rd part determines which number to return, is it number of complete YEAR, number of complete MONTH, or the number of DAYS left that cannot make up another month. So if we want to calculate the time between 19 May 2007 and 13 Mar 2009, we have to first enter the 2 dates into the worksheet, for example in A1 and B1. This will allow Excel to capture the serial number for the 2 dates. Then in Cell C1, you can enter the DATEDIF formula as follows: y indicates the command for the formula to return the number of full years from 19 May 2007 to 13 Mar 2009. In this case, there is only one full year (ie 19 May 2007 to 18 May 2008). Between 19 May 2008 and 13 Mar 2009 is less than one year. To calculate the number of months, you can enter a similar formula in cell D1 changing the "y" to "ym". This will command Excel to return the number of months from 19 May 2008 (one year before end date starting from the day and month of the start date) to 13 Mar 2009, giving us the number 9 for 9 months. And to calculate the days, you can copy the formula in D1 and put it in cell E1, changing the 3rd part to 'md". This will make Excel calculate the number of days from 19 Feb 2009 (one month before end date with day from start date) to 13 Mar 2009, which will return us 22 for 22 days between 19 Feb 2009 and 13 Mar 2009. Using Concatenate, you can combine the results into cell F1, so that it shows up as 1 year 9 months and 22 days. The formula is =C1&" years "&D1&" months "&E1&" days"
 * =DATEDIF(A1,B1,"y")**
 * =DATEDIF(A1,B1,"ym")**