6.5. The DBEngine Object

The DBEngine object is a property of the Access Application object, and represents the top-level object in the DAO model. The DBEngine object contains all the other objects in the DAO object hierarchy, yet unlike many of the other DAO objects, you can't create additional DBEngine objects.

The DBEngine object contains two major collections—Workspaces and Errors—which are described in this section because they relate so closely to the DBEngine object.

6.5.1. The Workspaces Collection

A workspace is a named user session that contains open databases and provides the facility for transactions and (depending on the database format) user-and group-level security. As you can have more than one workspace active at any time, the Workspaces collection is the repository for all the workspaces that have been created.

You use the Microsoft Access workspace to access Microsoft Access database engine databases (ACCDB files created in Access 2007), Microsoft Jet databases (MDB files created in previous versions), and ODBC or installable ISAM data sources through the Microsoft Access database engine. For a list of the collections, objects, and methods supported by Microsoft Access workspaces, refer to Appendix D.

The Workspace object contains three different object collections. These are Databases, Groups, and Users. Note that the Groups and Users collections are hidden in Access 2007 and you'll need to show them in the Object Browser before they will appear using IntelliSense. ...

Get Access™ 2007 VBA Programmer's Reference 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.