close
Hello,

I'm using the =Yearfrac formula to calculate tenure. It returns the result
in years and fractions of years; e.g., 5.5 yrs.

Is there any way that the interval between two dates can be calculated in
years and months, so that I get 5yrs 6months?

thanks!


You could use the DATEDIF function.

=DATEDIF(A1,NOW(),quot;yquot;) amp; quot; yrs, quot; amp; DATEDIF(A1,NOW(),quot;ymquot;) amp; quot; monthsquot;

HTH,

Steve--
SteveG
------------------------------------------------------------------------
SteveG's Profile: www.excelforum.com/member.php...foamp;userid=7571
View this thread: www.excelforum.com/showthread...hreadid=514994Hi

Try
=DATEDIF(earlydate,latedate,quot;yquot;)amp;quot; years
quot;amp;DATEDIF(earlydate,latedate,quot;ymquot;)amp;quot; monthsquot;
For more information on the undocumented datedif function, take a look
at Chip Pearson's site
www.cpearson.com/excel/datedif.htm

--
Regards

Roger Govier
Stilla wrote:
gt; Hello,
gt;
gt; I'm using the =Yearfrac formula to calculate tenure. It returns the
gt; result in years and fractions of years; e.g., 5.5 yrs.
gt;
gt; Is there any way that the interval between two dates can be
gt; calculated in years and months, so that I get 5yrs 6months?
gt;
gt; thanks!
WOW! This is like magic!!! THANK YOU!!!

quot;SteveGquot; wrote:

gt;
gt; You could use the DATEDIF function.
gt;
gt; =DATEDIF(A1,NOW(),quot;yquot;) amp; quot; yrs, quot; amp; DATEDIF(A1,NOW(),quot;ymquot;) amp; quot; monthsquot;
gt;
gt; HTH,
gt;
gt; Steve
gt;
gt;
gt; --
gt; SteveG
gt; ------------------------------------------------------------------------
gt; SteveG's Profile: www.excelforum.com/member.php...foamp;userid=7571
gt; View this thread: www.excelforum.com/showthread...hreadid=514994
gt;
gt;

Thanks Roger! works perfectly!

quot;Roger Govierquot; wrote:

gt; Hi
gt;
gt; Try
gt; =DATEDIF(earlydate,latedate,quot;yquot;)amp;quot; years
gt; quot;amp;DATEDIF(earlydate,latedate,quot;ymquot;)amp;quot; monthsquot;
gt; For more information on the undocumented datedif function, take a look
gt; at Chip Pearson's site
gt; www.cpearson.com/excel/datedif.htm
gt;
gt; --
gt; Regards
gt;
gt; Roger Govier
gt;
gt;
gt;
gt; Stilla wrote:
gt; gt; Hello,
gt; gt;
gt; gt; I'm using the =Yearfrac formula to calculate tenure. It returns the
gt; gt; result in years and fractions of years; e.g., 5.5 yrs.
gt; gt;
gt; gt; Is there any way that the interval between two dates can be
gt; gt; calculated in years and months, so that I get 5yrs 6months?
gt; gt;
gt; gt; thanks!
gt;
gt;
gt;

arrow
arrow
    全站熱搜

    software 發表在 痞客邦 留言(0) 人氣()