DAO Classes

DAO is used with Access databases and is supported through Office 2013. DAO 3.6 is the final version, and it is considered obsolete.

These classes work with the other application framework classes to give easy access to Data Access Object (DAO) databases, which use the same database engine as Microsoft Visual Basic and Microsoft Access. The DAO classes can also access a wide variety of databases for which Open Database Connectivity (ODBC) drivers are available.

Programs that use DAO databases will have at least a CDaoDatabase object and a CDaoRecordset object.

Note

The Visual C++ environment and wizards no longer support DAO (although the DAO classes are included and you can still use them). Microsoft recommends that you use ODBC for new MFC projects. You should only use DAO in maintaining existing applications.

CDaoWorkspace
Manages a named, password-protected database session from login to logoff. Most programs use the default workspace.

CDaoDatabase
A connection to a database through which you can operate on the data.

CDaoRecordset
Represents a set of records selected from a data source.

CDaoRecordView
A view that displays database records in controls.

CDaoQueryDef
Represents a query definition, usually one saved in a database.

CDaoTableDef
Represents the stored definition of a base table or an attached table.

CDaoException
Represents an exception condition arising from the DAO classes.

CDaoFieldExchange
Supports the DAO record field exchange (DFX) routines used by the DAO database classes. You will normally not directly use this class.

CLongBinary
Encapsulates a handle to storage for a binary large object (BLOB), such as a bitmap. CLongBinary objects are used to manage large data objects stored in database tables.

COleCurrency
Wrapper for the OLE automation type CURRENCY, a fixed-point arithmetic type, with 15 digits before the decimal point and 4 digits after.

COleDateTime
Wrapper for the OLE automation type DATE. Represents date and time values.

COleVariant
Wrapper for the OLE automation type VARIANT. Data in VARIANTs can be stored in many formats.

See also

Class Overview