'------------------------------------------------------------
Sub test()
Dim Dic As Object, C As Range
Dim DerLig As Long, T()
Set Dic = CreateObject("Scripting.Dictionary")
With Worksheets("Feuil2")
DerLig = .Range("A:B").Find("*", LookIn:=xlValues, _
SearchOrder:=xlByRows, _
SearchDirection:=xlPrevious).Row
'Si tu as des étiquettes de colonne
'Inscris A2 en lieu et place de A1
For Each C In .Range("A1:B" & DerLig)
If C <> "" Then
If Not Dic.exists(C.Value) Then
Dic.Add (C.Value), C.Address
End If
End If
Next
End With
T = Dic.keys
BubbleSort T()
With Worksheets("Feuil2").Shapes("ListBox1").OLEFormat.Object.Object
.Clear
.List = T
End With
End Sub
'------------------------------------------------------------
Sub BubbleSort(List())
' Sorts the List array in ascending order
Dim First As Integer, Last As Integer
Dim i As Integer, j As Integer
Dim Temp
First = LBound(List)
Last = UBound(List)
For i = First To Last - 1
For j = i + 1 To Last
If List(i) > List(j) Then
Temp = List(j)
List(j) = List(i)
List(i) = Temp
End If
Next j
Next i
End Sub
'------------------------------------------------------------
Si tu préfères afficher le résultat dans la colonne C pluôt que
directement dans le listbox à la fin de la procédure, tu remplaces
With Worksheets("Feuil2").Shapes("ListBox1").OLEFormat.Object.Object
.Clear
.List = T
End With
PAR
With Worksheets("Feuil2")
.Range("C1").Resize(UBound(T) + 1) = Application.Transpose(T)
End With