Platform SDK: CDO 1.2.1

Fields Property (AddressEntry Object)

The Fields property returns a single Field object or a Fields collection object. Read-only.

Syntax

objAddressEntry.Fields

objAddressEntry.Fields(index)

objAddressEntry.Fields(proptag)

objAddressEntry.Fields(name)

index
Integer. Value must be between 1 and 65535 (&HFFFF) inclusive. Specifies the index within the Fields collection.
proptag
Long. Value must be greater than or equal to 65,536 (&H10000). Specifies the property tag value for the MAPI property to be retrieved.
name
String. Specifies the name of the custom MAPI property.

Data Type

Object (Field or Fields collection)

Remarks

The Fields property returns one or all of the fields associated with an AddressEntry object. Each field typically corresponds to a MAPI property. Data types are preserved, except that MAPI counted binary properties are converted to and from character strings representing hexadecimal digits.

The Fields property provides a generic access mechanism that allows Microsoft® Visual Basic® and Microsoft® Visual C++® programmers to retrieve the value of any MAPI property using either a name or a MAPI property tag. For access with the property tag, use objAddressEntry.Fields(proptag), where proptag is the 32-bit MAPI property tag associated with the property, such as CdoPR_GIVEN_NAME. To access a named property, use objAddressEntry.Fields(name), where name is a string that represents the custom property name.

Although the Fields property itself is read-only, the collection it returns can be accessed in the normal manner through its Add and Delete methods, and the properties on its member Field objects retain their respective read/write or read-only accessibility.

You must have the appropriate permissions to add, delete, or modify fields on an AddressEntry object. Normally you only have these permissions on your personal address book (PAB). Furthermore, some address book containers such as the global address list (GAL) support only a fixed set of properties. Even if you have permissions on a container with a fixed schema, you cannot add new fields to its entries. An attempt to do so returns CdoE_NO_ACCESS.

The Fields property does not correspond to a MAPI property and cannot be rendered into HTML hypertext by the CDO Rendering Library.