Understanding COM - DevCon 2022

Links and resources from my talk today at Access DevCon Vienna 2022, Understanding COM.

Understanding COM - DevCon 2022

Slide Deck


Further Reading

High-Level COM Overview

What the #$%& is COM!?
One of the most important concepts in VBA is also one of the least understood. Let’s shine a light on the Component Object Model.
What is COM?
The concept of COM explained in under 100 words. #Under100
High Level Overview of COM
This whirlwind tour of the Component Object Model technology will jump start your journey of automating Excel from VBA in Access.
Overcoming Programming Language Barriers with COM
COM is sort of like a Chinese restaurant.
Early vs. Late Binding at the Chinese Restaurant
In this continuation of our Chinese restaurant-COM metaphor, we expand the example to illustrate the differences between early and late binding.
Managing Memory in COM
We continue on with our restaurant analogy to explain the concept of reference counting and COM object cleanup.
COM Server Types: In-Process vs. Local vs. Remote
There are three basic types of COM servers: in-process, local, and remote. What do they have in common? What are the differences? Let’s explore.

Low-Level Details

The IUnknown Interface
All COM objects are required to support at least one interface: the IUnknown interface. In this short article, we explore the three methods of IUnknown.
The IDispatch Interface
For a COM object to support late binding in VBA, it must implement the IDispatch interface. Let’s explore IDispatch and its four methods.
Reference Counting’s Fatal Flaw: Circular References
We look at several types of circular references along with a handy tool that you can use to help identify circular references in your own code.
Loading VBE Addins - A Windows Registry Tour
Let’s pull back the curtain and see how VBA loads VBE COM add-ins via a series of registry calls.

Practical Applications

Microsoft Office COM Automation Libraries
The VBA developer’s guide to automating Microsoft Office applications: early vs late binding; CreateObject vs GetObject; and tips on cleaning up after yourself.
Early Binding vs. Late Binding: The Essential Guide for VBA Developers
The Absolute Minimum Every VBA Developer Absolutely, Positively Must Know About Early and Late Binding in COM (No Excuses!)

Future Presentations

If you enjoyed today's presentation, you can catch me at the following upcoming events:

Access Europe – Mike Wolfe (Building Ribbon Interfaces in Code) – Europe – AccessUserGroups.org

All original code samples by Mike Wolfe are licensed under CC BY 4.0