Try something like the following:
Private Sub CommandButton1_Click()
Dim Dict As Object
Dim Rng As Range
Dim V As Variant
Set Dict = CreateObject("Scripting.Dictionary")
For Each Rng In Range("A1:A20") '<<< CHANGE
If Dict.exists(Rng.Text) = False Then
Dict.Add key:=Rng.Text, Item:=Rng.Text
End If
Next Rng
With Me.ListBox1
.Clear
For Each V In Dict.items
.AddItem V
Next V
End With
End Sub
--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
"Brandon Johnson" wrote in message
ups.com...
i have a column of duplicate text values. i want to extract the
values
and have a compact list of not duplicated values. is there any
way to
do this. example:
(at moment) (want)
rgn rgn
north North
east East
east South
east West
north
south
south
east
west
west
south
.
.
.
and so on.