T
turay
Hi I received this great response to an earlier post that I have made
concerning the following sweep:
http://www.standardsbigbid.com/londonapartment/php/Help.php#works,
...and would need the kind of illustration, a pretty much excel novice person
like myself, would need. Thanks for your (listening) time :-
input range is Rng1 and the output range is Rng2.
Sub ListUniqueVal()
Dim Rng1 As Range
Dim Rng2 As Range
Dim Cell As Range
Dim UniqueValues As New Collection
Set Rng1 = Range("B4:C10")
Set Rng2 = Range("E4")
On Error Resume Next
For Each Cell In Rng1
UniqueValues.Add Cell.Value, CStr(Cell.Value)
Next Cell
For Each Item In UniqueValues
Rng2.Value = Item
Set Rng2 = Rng2.Offset(1, 0)
Next Item
End Sub
John Mansfield
pdbook.com
concerning the following sweep:
http://www.standardsbigbid.com/londonapartment/php/Help.php#works,
...and would need the kind of illustration, a pretty much excel novice person
like myself, would need. Thanks for your (listening) time :-
Hi, the following macro will extract unique values. The-----Original Message-----
input range is Rng1 and the output range is Rng2.
Sub ListUniqueVal()
Dim Rng1 As Range
Dim Rng2 As Range
Dim Cell As Range
Dim UniqueValues As New Collection
Set Rng1 = Range("B4:C10")
Set Rng2 = Range("E4")
On Error Resume Next
For Each Cell In Rng1
UniqueValues.Add Cell.Value, CStr(Cell.Value)
Next Cell
For Each Item In UniqueValues
Rng2.Value = Item
Set Rng2 = Rng2.Offset(1, 0)
Next Item
End Sub
John Mansfield
pdbook.com