Chapter 8Custom Collections and Class Modules

You are not limited to using objects built into Microsoft Office Access. VBA allows you to create your own objects and collections of objects, complete with their own methods and properties. In this chapter, you learn how to work with collections, including how to declare a custom Collection object. You also learn how to use class modules to create user-defined objects.


Before diving into theory and the hands-on examples of this chapter, let’s start by going over several terms that will be used throughout this chapter.

Collection — An object that contains a set of related objects.

Class — A definition of an object that includes its name, properties, methods, and events. The class acts as ...

Get Access 2007 Programming by Example with VBA, XML, and ASP now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.