Private Sub Worksheet_Activate()
Dim d As Object, ncol%, tablo, i%, j%, dat, P As Range, resu()
Set d = CreateObject("Scripting.Dictionary")
With Sheets("saisie des dates").UsedRange
ncol = 2 * Int(.Columns.Count / 2) 'nombre pair
If ncol = 0 Then ncol = 2 'sécurité
tablo = .Resize(, ncol) 'matrice, plus rapide
End With
'---listes des dates sans doublon et des textes---
For i = 2 To UBound(tablo)
For j = 3 To ncol Step 2
dat = tablo(i, j)
If IsDate(dat) Then d(dat) = tablo(i, j + 1)
Next j, i
'---traitement de la feuille---
Set P = [C5:C35]
For j = 0 To 11
tablo = P.Offset(, 4 * j) 'matrice, plus rapide
ReDim resu(1 To 31, 1 To 1)
For i = 1 To 31
dat = tablo(i, 1)
If IsDate(dat) Then If d.exists(dat) Then resu(i, 1) = d(dat)
Next i
P.Offset(, 4 * j + 1) = resu 'restitution
Next j
End Sub