O'Reilly logo

CDO & MAPI Programming with Visual Basic: by Dave Grundgeiger

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The CDO Object Model

The CDO object model contains 23 classes. These classes are defined in the type library contained in the file cdo.dll. This type library also contains the declarations of these classes’ numerous properties, methods, and constants. (CDO objects don’t expose any events.) The remainder of this chapter examines the relationships among the CDO classes, and briefly describes the most important of their methods, etc. Throughout the remainder of the book, these features will be examined in detail. It should be noted that cdo.dll contains more than just the type library for CDO; it also contains the executable code that implements CDO’s features.

The first order of business is to set a reference to the CDO type library. From the Visual Basic menu, choose Project References to display the References dialog box (already shown in Figure 5-1). Scroll down the list of available references until you find “Microsoft CDO version number Library,” where version number should be 1.x in order to work with the samples in this book. Select this item if it’s not already selected, and click OK.

Tip

If you don’t find “Microsoft CDO 1.21 Library” in your list of available references, either you don’t have cdo.dll on your system or it hasn’t been registered (i.e., the location of this file hasn’t been noted in the Windows Registry). Search your local hard drive(s) for cdo.dll. If you find it, return to the References dialog box and click Browse. Browse to cdo.dll and click Open, then ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required