[A2].Sort Key1:=Range("A2"), Order1:=xlAscending, Header:=xlGuess
i = 2
Do While Cells(i, 1) <> ""
If Cells(i, 1) = Cells(i + 1, 1) Then Rows(i).Delete Else i = i + 1
Loop
la séquence "Delete" supprime tous les éléments de la ligne.
Ma question:
Y a t'il un moyen de limiter le "Delete" au 2 premieres colonnes (A & B)
Dim i&
With Range("A2", Cells.SpecialCells(xlCellTypeLastCell))
.Sort .Columns(1), xlAscending, Header:=xlGuess
For i = .Rows.Count To 2 Step -1
If .Cells(i, 1) = .Cells(i - 1, 1) Then .Rows(i).Resize(, 2).Delete xlUp
Next
End With