bonjour,
une nouvelle proposition
Sub aargh()
Set ws = Sheets("feuil2")
With Sheets("feuil1")
dl = .Cells(Rows.Count, 1).End(xlUp).Row
.Columns(1).Insert shift:=xlToRight
.Range("A1") = 1
.Range("A2") = 2
.Range("A1:A2").AutoFill Destination:=.Range("A1:A" & dl)
.Range("A1:I" & dl).Sort key1:=.Range("C1"), order1:=xlAscending, key2:=.Range("I1"), order2:=xlDescending, Header:=xlYes
pr = ""
k = 1
For i = 2 To dl + 1
If .Cells(i, 3) <> pr Then
If pr <> "" Then
If kv <> 0 Then
For j = fk To k
ws.Cells(j, 3) = .Cells(kv, 2)
ws.Cells(j, 4) = .Cells(kv, 9)
Next j
Else
ws.Rows(fk & ":" & k).ClearContents
k = fk - 1
End If
End If
kv = 0
pr = .Cells(i, 3)
fk = k + 1
End If
Select Case .Cells(i, 8)
Case "+ 24 Mois", "de 12 à 24 Mois"
k = k + 1
ws.Cells(k, 1) = pr
ws.Cells(k, 2) = .Cells(i, 2)
ws.Cells(k, 5) = .Cells(i, 7)
Case Else
If kv = 0 Then kv = i
End Select
Next i
.Range("A1:I" & dl).Sort key1:=.Range("A1"), order1:=xlAscending, Header:=xlYes
.Columns(1).Delete shift:=xlToLeft
End With
End Sub