Export (0) Print
Expand All
Expand Minimize

ContactItem.Email3EntryID Property

Office 2007
Returns a String representing the entry ID of the third e-mail entry for the contact. Read-only.

Syntax

expression.Email3EntryID

expression   A variable that represents a ContactItem object.

Remarks

This property corresponds to the MAPI named property dispidEmail3OriginalEntryID.

If you are getting this property in a Microsoft Visual Basic or Microsoft Visual Basic for Applications (VBA) solution, owing to some type issues, instead of directly referencing Email3EntryID, you should get the property through the PropertyAccessor object returned by the ContactItem.PropertyAccessor property, specifying the MAPI property dispidEmail3OriginalEntryID property and its MAPI id namespace. The following code sample in VBA shows the workaround.

Visual Basic for Applications
Public Sub GetEmail3EntryID()
    Dim objContactFolder As Outlook.Folder
    Dim objContactItem As Outlook.ContactItem
    Dim objRec As Outlook.Recipient
    Dim strEntryID As String
    Dim oPA As Outlook.PropertyAccessor
    Const PR_EMAIL3_ENTRYID As String = "http://schemas.microsoft.com/mapi/id/{00062004-0000-0000-C000-000000000046}/80A50102"

    Set objContactFolder = Application.Session.GetDefaultFolder(olFolderContacts)
    Set objContactItem = objContactFolder.Items(1)
    Set oPA = objContactItem.PropertyAccessor
    strEntryID = oPA.BinaryToString(oPA.GetProperty(PR_EMAIL3_ENTRYID))
    Debug.Print strEntryID
    Set objRec = Application.Session.GetRecipientFromID(strEntryID)
    If objRec Is Nothing Then
        Debug.Print "GetRecipientFromID failed"
    Else
        Debug.Print objRec.Name
        Debug.Print objRec.EntryID
    End If

    'Cleanup
    Set objContactItem = Nothing
    Set objContactFolder = Nothing
End Sub



Community Additions

ADD
Show:
© 2014 Microsoft