Re:a l'attention de Pierrejean
bonsoir JJ bonsoir porcinet
je ne t'en veux absolument pas porcinet
JJ je te propose quelque chose qui n'est pas tres elegant mais qui je crois fonctionne
(je continue a potasser le probleme qui se complique car a chaque effacement de ligne il ya modification des numeros de ligne)
Sub test()
Dim tablo()
Dim tab1 As Integer
fin = Range('F1').End(xlDown).Row
For n = 1 To fin
If Cells(n, 6).Interior.ColorIndex = 3 Then
Rows(n).Copy Destination:=Rows(fin + 1 + tab1)
ReDim Preserve tablo(tab1 + 1)
tablo(tab1 + 1) = n
tab1 = tab1 + 1
End If
Next
b = 1
For n = 1 To tab1
If n = 1 Then
Rows(tablo(n)).Delete
Else
Rows(tablo(n) - b).Delete
b = b + 1
End If
Next
End Sub
|