Foto

The Microsoft Access type library provides information about Microsoft Access objects to other components. You can set a reference to the Microsoft Access type library from a component and view its objects in the Object Browser.

Microsoft Access is a COM component that supports Automation, formerly called OLE Automation. Microsoft Access supports Automation in two ways. From Microsoft Access, you can work with objects supplied by another component. Microsoft Access also supplies its objects to other COM components.

You can use the New keyword or the CreateObject method to create a new instance of a component. You can use the GetObject method to assign a variable to an existing instance of a component.

In Microsoft Access, you can set a reference to a components type library to improve performance when you work with that component through Automation. Microsoft Access also includes the Object Browser, a tool that enables you to view objects in another components type library, as well as their methods and properties.

Once youve launched an instance of Microsoft Access, if you want to control any Microsoft Access objects, you must open a database or project (.adp) in the Microsoft Access window by using either the OpenCurrentDatabase or the NewCurrentDatabase method for a database or by using the OpenAccessProject or the NewAccessProject method for a project.

If youve opened Microsoft Access only as a means of using the Data Access Objects provided by Microsoft DAO, then you don need to open a database in the Microsoft Access window. You can use the DBEngine property of the Microsoft Access Application object to access objects in the Microsoft Office 12.0 Access Database Engine Object Library object library during an Automation operation.