Hi,
I am new to Visual basic but I have some java experience. I have a single column of data as text strings in an excel doc and I would like to use some code to sort that list and output two columns. the first with unique strings and the second with the frequency of that string in the original list.
here is an example of what i want the code to do
List:
Fruits
apple
apple
apple
melon
orange
apple
grape
orange
apple
melon
grape
output:
Fruit Frequency
apple 5
orange 2
grape 2
melon 2
I have been researching this for the past few days but I can't seem to figure out if it is possible to sort this way in VBA. I know there is a way to do it in java with arrays or array lists. Any help would be much appreciated.
I am new to Visual basic but I have some java experience. I have a single column of data as text strings in an excel doc and I would like to use some code to sort that list and output two columns. the first with unique strings and the second with the frequency of that string in the original list.
here is an example of what i want the code to do
List:
Fruits
apple
apple
apple
melon
orange
apple
grape
orange
apple
melon
grape
output:
Fruit Frequency
apple 5
orange 2
grape 2
melon 2
I have been researching this for the past few days but I can't seem to figure out if it is possible to sort this way in VBA. I know there is a way to do it in java with arrays or array lists. Any help would be much appreciated.