si tu pouvais me dire quel est le mot à changer pour que le prog. cherche désormais le groupe de cellules non vides contiguës selon la même forme 11224112421133 dans une seule cellule
Function NbCellVid(Plage As Range, Seuil As Long) As String
Dim Cellule As Range, Compte As Long, Maxi As Long
NbCellVid = "non"
Maxi = 0
For Each Cellule In Plage
If Cellule.Value <> "" Then
If Compte > Maxi Then Maxi = Compte
Compte = 0
Else
Compte = Compte + 1
End If
Next Cellule
If Compte > Maxi Then Maxi = Compte
If Maxi > Seuil Then NbCellVid = "oui"
End Function
=NbCellVid(A4:A41;8)