A couple of issues jump out at me here.
In your For...Each...Next loop:
You recreate a new collection named "UniqRow".
A collection is not an array.
You read each cell of the worksheet. This is rather slow.
Suggestion:
Dump the entire sheet into an array and work the array to remove
duplicate rows.
Example:
Dim vData As Variant, vaNums()
Dim i As Long, k As Long
vData = ActiveSheet.UsedRange
For i = LBound(vData) To UBound(vData)
If vData(i, 3) = "X" Then
ReDim Preserve vaNums(k)
vaNums(k) = vData(i, 1): k = k + 1
End If
Next 'i
Now, vaNums is na array that contains a list of the numbers in ColA
where ColC contained "X".
--
Garry
Free usenet access at
http://www.eternal-september.org
ClassicVB Users Regroup! comp.lang.basic.visual.misc