How do I count the instances of numbers in a list?
Assume the 152 unique number list is in column D and the original list is in
Column A
Sub Countem()
Dim rng as Range
set rng = range(cells(1,"D"),cells(1,"D").End(xlup))
rng.offset(0,1).Formula = "=countif(A:A,D1)"
rng.offset(0,1).formula = rng.offset(0,1).value
End Sub
--
Regards,
Tom Ogilvy
"John@NGC" wrote:
I have a list of numbers, most duplicates. I have a sorted list of the 152
unique numbers in a separate column. I need a VBA routine to list the times
each number is used beside the unique number column. Any help is appreciated.
John
|