Microsoft ActiveX Data ObjectsMicrosoft ActiveX Data Objects*
*Contents  *Index  *Topic Contents

Attributes Property - ADO

Indicates one or more characteristics of an object.

Applies To

Connection, Field, Parameter, Property

Settings and Return Values

Sets or returns a Long value.

For a Connection object, the Attributes property is read/write, and its value can be the sum of any one or more of these XactAttributeEnum values (default is zero):
Constant Description
adXactCommitRetaining Performs retaining commits, that is, calling CommitTrans automatically starts a new transaction. Not all providers support this.
adXactAbortRetaining Performs retaining aborts, that is, calling RollbackTrans automatically starts a new transaction. Not all providers support this.

For a Parameter object, the Attributes property is read/write, and its value can be the sum of any one or more of these ParameterAttributesEnum values:
Constant Description
adParamSigned Default. Indicates that the parameter accepts signed values.
adParamNullable Indicates that the parameter accepts Null values.
adParamLong Indicates that the parameter accepts long binary data.

For a Field object, the Attributes property is read-only, and its value can be the sum of any one or more of these FieldAttributeEnum values:
Constant Description
adFldMayDefer Indicates that the field is deferred, that is, the field values are not retrieved from the data source with the whole record, but only when you explicitly access them.
adFldUpdatable Indicates that you can write to the field.
adFldUnknownUpdatable Indicates that the provider cannot determine if you can write to the field.
adFldFixed Indicates that the field contains fixed-length data.
adFldIsNullable Indicates that the field accepts Null values.
adFldMayBeNull Indicates that you can read Null values from the field.
adFldLong Indicates that the field is a long binary field. Also indicates that you can use the AppendChunk and GetChunk methods.
adFldRowID Indicates that the field contains some kind of record ID (record number, unique identifier, and so forth).
adFldRowVersion Indicates that the field contains some kind of time or date stamp used to track updates.
adFldCacheDeferred Indicates that the provider caches field values and that subsequent reads are done from the cache.

For a Property object, the Attributes property is read-only, and its value can be the sum of any one or more of these PropertyAttributesEnum values:
Constant Description
adPropNotSupported Indicates that the property is not supported by the provider.
adPropRequired Indicates that the user must specify a value for this property before the data source is initialized.
adPropOptional Indicates that the user does not need to specify a value for this property before the data source is initialized.
adPropRead Indicates that the user can read the property.
adPropWrite Indicates that the user can set the property.

Remarks

Use the Attributes property to set or return characteristics of Connection objects, Parameter objects, Field objects, or Property objects.

When you set multiple attributes, you can sum the appropriate constants. If you set the property value to a sum including incompatible constants, an error occurs.

Remote Data Service Usage This property is not available on a client-side Connection object.

Examples

Attributes and Name Properties Example (VB)


Up Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.