J'ai profité du passage d'un presta pour lui poser la question, et il m'a fait ce code qui va bien.
Sub Proteger()
Dim I, pas_fini
I = 1
pas_fini = True
Dim MdP As String
ActiveSheet.Unprotect
While (pas_fini)
If (Left(Cells(I, 1).Value, 13) = "RECAPITULATIF") Then
I = I + 4
With Range(Cells(I, 3), Cells(I + 2, 9))
.Locked = False
With .Interior
.ColorIndex = 0
.Pattern = xlSolid
End With
End With
I = I + 4
'MsgBox ("tit " & i)
Else
If (Left(Cells(I, 2).Value, 11) = "Heure début") Then
With Range(Cells(I, 3), Cells(I + 2, 9))
.Locked = False
With .Interior
.ColorIndex = 0
.Pattern = xlSolid
End With
End With
I = I + 4
Else
pas_fini = False
End If
End If
Wend
MdP = "PRESSTALIS"
ActiveSheet.Protect MdP, DrawingObjects:=True, Contents:=True, Scenarios:=True
End Sub
J'ai pas tout compris, mais ça marche. Alors si ça peut être utile à d'autre(s)...