All the references that you’ve selected will appear at the top of this huge list, with ticks next to them. So you won’t ever need to search the whole list for an elusive tick!
What references might you want? Well one that I use regularly is the Microsoft Scripting Runtime. This gives you access to the Visual Basic Scripting Object Model, with notable inclusions the Dictionary object and the FileSystemObject.
- Dictionary objects are very similar to Collections in VBA but with some useful additional features. If you want to check if an item exists in your Dictionary object then use the Dictionary.Exists method. And Dictionaries also provide you with a list of the unique IDs of its elements using the Dictionary.Keys property.
- FileSystemObject is a very powerful tool in scripting. You can recurse through Files in a folder or subfolders of a parent folder, create and delete folders and files, check if folders and files exist and so on. It’s an extremely powerful tool – I may well do a future post dedicated to it.
Another reference I’ve used recently is the CAPICOM Type Library. I needed a hash function to help me validate some data, so decided to use the MD5 algorithm. (If you don’t know what a hash function is, it’s essentially just a fancy checksum but it works on text data as well.) Adding the CAPICOM reference gives you the HashedData object, which can be used to generate a variety of hash functions.
As mentioned at the top, you can even create references to other Excel addins, giving you access to all the same functions and macros. This can make for some helpful ways to organise and simplify code.
All in all references are an extremely powerful tool and well worth getting acquainted with. If you’re interested in investigating the Microsoft Scripting Runtime further then I’d also recommend checking out the VB script pages at http://www.devguru.com for a handy reference.