bonjour,
Sub ValeursEntre()
Dim iValue As Integer, MonMin As Integer, MonMax As Integer, L, C
Set sca = CreateObject("system.collections.arraylist")
For L = 11 To 23 'boucle ces lignes
For C = 1 To 2 '2 recherches
Select Case C
Case 1: MonMin = 4300: MonMax = 4500 'recherche 1
Case Else: MonMin = 4501: MonMax = 4600 'l'autre
End Select
sca.Clear 'RAZ
s = Cells(L, "A").Value2
If Len(s) > 0 Then
sp = Split(s, ";") 'divider sur le ";"
For j = 0 To UBound(sp)
If IsNumeric(sp(j)) Then
iValue = sp(j)
If MonMin <= iValue And iValue <= MonMax Then
If Not sca.contains(iValue) Then sca.Add iValue
End If
End If
Next
End If
If sca.Count Then
sca.Sort
Cells(L, "C").Offset(, C).Value = "'" & Join(sca.toarray, ";")
Else
Cells(L, "C").Offset(, C).Value = "Texte en cas d'erreur"
End If
Next
Next
End Sub