I used the dictionary to remove dupplicates.
I have a list of students who failed and I wanted a list with all the subjects, as many students failed the same subjects I had to remove dupplicates. I worked from the worksheet without using an array, but it is easy to adapt this code by writing the info in an array first and after send the array to the function.
It's a code snippet I don't use regularly, so I didn't optimise it, my excuses , it's a draft "as it is"
'Note: You will need to add a reference to "Microsoft Scripting Runtime" as the code uses its Dictionary object.
'To do this, select Tools from the toolbar, then select "References", and then select "Microsoft Scripting Runtime"
Good luck
Bookmarks