Introduction to Using Events

Note

This and the remaining sections of this chapter are intended to provide a taste of some additional capabilities of VBA beyond the basic macro, for those who feel confident with the primer content to this point and would like to try something a bit more complex. These sections assume you’ve already mastered everything included in the primer to this point.

Events in VBA are procedures that run automatically when a specified event occurs. There are several types of events in VBA, such as those that occur with a specific document action (such as opening a document), an application-specific action (such as exiting the program), or an action taken in a dialog box (such as clicking a command button). In this section, the ...

Get 2007 Microsoft® Office System Inside Out now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.