Código Delphi [-] d,d1:TDateTime; yearsouble; begin d := encodedatetime(2006,5,12,10,0,0,0); d1 := d-Now; years := YearsBetween(d,Now); Memo1.Lines.Add(FloatToStr(years)+' años '+IntToStr(MonthOf(d1)) +' meses y '+ IntToStr(dayof(d1))+ ' dias' );
d,d1:TDateTime; yearsouble; begin d := encodedatetime(2006,5,12,10,0,0,0); d1 := d-Now; years := YearsBetween(d,Now); Memo1.Lines.Add(FloatToStr(years)+' años '+IntToStr(MonthOf(d1)) +' meses y '+ IntToStr(dayof(d1))+ ' dias' );