hi everyone,

I have the following code which currently works great for creating a unique list:

Sub Uniq_List1()

Dim a As Variant, x As Variant, i As Long, J, n&
Application.ScreenUpdating = False

With Sheets("Data").Range("N2").CurrentRegion
a = .Value
End With
With CreateObject("scripting.dictionary")
.CompareMode = 1
For i = 1 To UBound(a, 1)
If a(i, 14) <> vbNullString Then
If Not .exists(a(i, 14)) And a(i, 16) = "NDev" Then
.Item(a(i, 14)) = Empty
End If
End If
Next
x = .Keys: n = .Count
End With
With Sheets("Output")
.Range("A7:A31").ClearContents
.Range("A7").Resize(n, 1) = Application.Transpose(x)
End With
Application.ScreenUpdating = True

Every item generated can be found in a list in column Z:Z. However, not every item is Z:Z could be listed since the data is relatively random.

What I'd like to do is still generate the unique list as the macro does, but order the list based on the list in Z:Z. If some items are missing in the macro list then it just skips over to the next one that's found in Z:Z.

I'm seriously a bit stumped on this one. Any ideas?

Thanks!