DAO Property Types
In contrast to Access object properties, the three types of object properties are: built-in, system-defined, and user-defined.
- Built-in properties exist when the object is created, and like most of their Access counterparts, define the characteristics of the object itself. For example, Name and Type are examples of builtin properties.
- System-defined properties are those that Access adds to the object's Properties collection when it needs the property in order to work its magic. These are not Access database engine properties, but are created and used by Access.
- A user-defined property can be added to an object's Properties collection when you explicitly set a value to it. For example, a field's Description property is a user-defined property. Although you can set a value to it when you define the table, Access doesn't recognize that the property exists until after you've done so. In fact, after you've set its value, it appears in the field's Properties collection, but you still can't see it in the Object Browser.
Creating, Setting, and Retrieving Properties
Without even thinking about it, you've been setting and retrieving properties for as long as you've been programming. Whenever you check the value of a TextBox, or set the Enabled state of a command button, you are working with object properties. This section explores how to manipulate Access properties, object properties, and user-defined properties.
You can refer to built-in properties either directly through the object to which they belong or through the object's Properties collection. User-defined properties, on the other hand, do not form part of an object's type library, and thus are not available via that route, so you have to refer to them through the object's Properties collection.
In this tutorial:
- Using DAO to Access Data
- Data Access Objects
- New Features in DAO
- Referring to DAO Objects
- The DBEngine Object
- Using Transactions
- The Errors Collection
- The Databases Collection
- The CurrentDb() Function
- Opening an External Database
- Closing and Destroying Database Object References
- DAO Property Types
- Setting and Retrieving Built-In Object Properties
- Setting and Retrieving SummaryInfo Properties
- Creating Schema Objects with DAO
- Creating Indexes
- Creating Relations
- Creating Multi-Value Lookup Fields
- Database Encryption with DAO
- Setting Encryption Options
- Managing Access (JET) Security with DAO
- Creating Security Objects
- Creating and Deleting Groups
- Managing Passwords
- Data Access with DAO
- Modifying a QueryDef
- Filtering and Ordering Recordsets
- Navigating Recordsets
- BOF, EOF
- Navigating Recordsets with Multi-Value Lookup Fields
- Bookmarks and Recordset Clones
- Finding Records
- Working with Recordsets
- Using Arrays with Recordsets
- Working with Attachment Fields
- Append Only Fields