VBA - Dictionary Object to identify Unique Values then count occurences given a set bucket of criterias
Posted on 2008-06-17
Hi, I'm still new to VBA and I have to use VBA to determine of a weekly list, the top 20 unique counterparties failing for trades over 30 days.
I read the Dictionary object is the most efficient but I'm having difficulties finding an example to learn from. If the counterparty names are in column "A" and failed days are in B, how could I use the dictionary object to form a list of total unique counterparties then count the occurrences given if the days failng >30. Your help is much appreciated. I read it involves .add then .exist and then looping it. A template would be awesome. In addition, should I use early binding or late binding for this code? Thanks everyone.