Private Sub Worksheet_Change(ByVal Target As Range)
Dim P As Range, dat, an%, mois As Byte, i&, x$, tablo, ub&, j&
Set P = [J15:M27]
dat = [L10] & "/" & [L11]
Application.ScreenUpdating = False
Application.EnableEvents = False 'désactive les évènements
P.ClearContents 'RAZ
If IsDate(dat) Then
dat = CDate(dat)
an = Year(dat): mois = Month(dat)
P(1, 2) = an & IIf(mois > 1, "/" & an + 1, "")
P(1, 3) = an + 1 & IIf(mois > 1, "/" & an + 2, "")
P(1, 4) = an + 2 & IIf(mois > 1, "/" & an + 3, "")
For i = 0 To 11
P(i + 2, 1) = Format(DateSerial(an, mois + i, 1), "mmmm")
Next
x = LCase(P(2, 1)) & an
tablo = [A7].CurrentRegion 'matrice, plus rapide
ub = UBound(tablo)
For i = 1 To ub
If LCase(Trim(tablo(i, 1))) & Trim(tablo(i, 2)) = x Then
For j = i To i + 11
If j > ub Then Exit For
P(2 + j - i, 2) = tablo(j, 3)
Next j
For j = j To i + 23
If j > ub Then Exit For
P(2 + j - i - 12, 3) = tablo(j, 3)
Next j
For j = j To i + 35
If j > ub Then Exit For
P(2 + j - i - 24, 4) = tablo(j, 3)
Next j
Exit For
End If
Next i
End If
Application.EnableEvents = True 'réactive les évènements
End Sub