Platform SDK: CDO 1.2.1 |
The ID property returns the unique identifier of the Recipient object as a string. Read/write.
objRecipient.ID
String
MAPI assigns a permanent, unique identifier when an object is created. This identifier does not change from one MAPI session to another, nor from one messaging domain to another. However, MAPI does not require identifier values to be binary comparable. Accordingly, two identifiers can have different values, yet refer to the same object. In particular, one of them could be a short-term identifier and the other a long-term identifier; these are constructed using different formats.
MAPI compares identifiers with the CompareEntryIDs method, which takes into account the differences between identifier formats and returns True if the identifiers are assigned to the same object. CDO provides the CompareIDs method in the Session object, which furnishes the same functionality. For more information on entry identifiers, see the MAPI Programmer’s Reference.
Although the AddressEntry and Recipient objects are not identical objects in the CDO Library, they represent the same underlying MAPI messaging user object, and the address entry’s ID property is equal to the recipient’s ID property. This can be used to advantage, for example, when adding an existing AddressEntry object to a Recipients collection. You can use the address entry’s ID property as the entryID parameter to the Add method.
If you attempt to set the ID property to an empty string, CdoE_INVALID_PARAMETER is returned.
The ID property corresponds to the MAPI property PR_ENTRYID, converted to a string of hexadecimal characters.