Function AnsMoisJours$(dat1, dat2)
If Not IsDate(dat1) Or Not IsDate(dat2) Then Exit Function
If dat2 < dat1 Then Exit Function
Dim a%, m%, test As Boolean, j%
a = Evaluate("DATEDIF(" & CDbl(dat1) & "," & CDbl(dat2) & ",""y"")")
m = Evaluate("DATEDIF(" & CDbl(dat1) & "," & CDbl(dat2) & ",""ym"")")
test = dat2 < DateSerial(Year(dat2), Month(dat2), Day(dat1)) 'True = -1
j = dat2 - DateSerial(Year(dat2), Month(dat2) + test, Day(dat1))
AnsMoisJours = RTrim(IIf(a, a & " an" & IIf(a = 1, " ", "s "), "") & IIf(m, m & " mois ", "") & IIf(j, j & " jour" & IIf(j = 1, "", "s"), ""))
End Function