O'Reilly logo

Microsoft® Access® 2010 24-Hour Trainer by Truitt L. Bradly, Geoffrey L. Griffith

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

57

Working with DAO

Data Access Objects (DAO) is a set of classes for working directly with the data objects of an Access database, and most commonly, the Table and Query objects of a database. The DAO collection of classes are specific to Microsoft Access and are used directly within the Access Object Model to provide the functionality for working directly with Access data objects. Although DAO provides quite a bit of functionality, this lesson provides a brief overview of using DAO to add, modify, and delete data in an Access database application.

LESSON SETUP

This lesson is designed to provide a basic overview of working with DAO to access data using VBA code. You should be familiar with Access databases, creating modules, and the basics of VBA programming. Also, this lesson uses some strings that are written in the SQL language, so having an understanding of SQL language and how to build SQL statements will aid in better understanding the uses of DAO, though it is not necessarily required. Otherwise, this lesson does not require any other specific knowledge of Access.

THE DAO OBJECT MODEL

The DAO object model contains 15 major object types: DBEngine, Workspace, Database, TableDef, QueryDef, Recordset, Container, Relation, Field, Index, Parameter, Document, User, Group, and Error objects. All of these classes together provide a great deal of functionality for working with many different aspects of an Access database. However, in the interest of sticking to the basics, this lesson ...

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