I have a formula for identifying years, months, days from a past date to
now. DATEDIF(C6,NOW(),"y")&" Y, "& DATEDIF(C6,NOW(),"ym")& " M, " &
DATEDIF(C6,NOW(),"md") & " D"
I'd like a formula that can produce the same format (years, months, days)
between now and a future date.
Any ideas?
Thanks in advance,
Bart
Ron de Bruin - 01 Sep 2006 20:54 GMT
Hi Bart
Try this with the date in A2
=IF(TODAY()<=A2,DATEDIF(TODAY(),A2,"Y") & " y " & DATEDIF(TODAY(),A2,"ym") & " m","-"&DATEDIF(A2,TODAY(),"y")& " y "
&DATEDIF(A2,TODAY(),"ym")& " m")

Signature
Regards Ron de Bruin
http://www.rondebruin.nl
>I have a formula for identifying years, months, days from a past date to now. DATEDIF(C6,NOW(),"y")&" Y, "& DATEDIF(C6,NOW(),"ym")&
>" M, " & DATEDIF(C6,NOW(),"md") & " D"
[quoted text clipped - 6 lines]
>
> Bart
Ron de Bruin - 01 Sep 2006 20:56 GMT
Oops, This is the correct one for YMD
=IF(TODAY()<=A2,DATEDIF(TODAY(),A2,"y") & " y " & DATEDIF(TODAY(),A2,"ym") & " m " & DATEDIF(TODAY(),A2,"md") & "
d","-"&DATEDIF(A2,TODAY(),"y") & " y " &DATEDIF(A2,TODAY(),"ym") & " m " &DATEDIF(A2,TODAY(),"md") & " d ")

Signature
Regards Ron de Bruin
http://www.rondebruin.nl
>I have a formula for identifying years, months, days from a past date to now. DATEDIF(C6,NOW(),"y")&" Y, "& DATEDIF(C6,NOW(),"ym")&
>" M, " & DATEDIF(C6,NOW(),"md") & " D"
[quoted text clipped - 6 lines]
>
> Bart
bam - 01 Sep 2006 21:06 GMT
Wow, nice. That does it. Thanks very much
Bart
> Oops, This is the correct one for YMD
>
[quoted text clipped - 14 lines]
>>
>> Bart
Gord Dibben - 01 Sep 2006 21:13 GMT
Swap your references around.
DATEDIF(NOW(),C6, etc.
Earliest date must be first.
Gord Dibben MS Excel MVP
>I have a formula for identifying years, months, days from a past date to
>now. DATEDIF(C6,NOW(),"y")&" Y, "& DATEDIF(C6,NOW(),"ym")& " M, " &
[quoted text clipped - 8 lines]
>
>Bart