Returns the address of a message recipient.
Syntax
object.Recipient(Index)
Remarks
The Recipient property array is used to enumerate the
recipient addresses that have been specified in the current
message. This includes all of the addresses listed in the To, Cc
and Bcc header fields. Only the address itself will be returned,
not any comments or extraneous text such as the full name of the
recipient. This property array is zero based, meaning that the
first index value is zero. The total number of recipients specified
in the message can be determined by checking the value of the
Recipients property.
Data Type
String
Example
The following example demonstrates how to use the
Recipient property array and the Recipients
property:
' Create a comma separated list of all of the recipient email
' addresses currently specified in the message
Dim strRecipients As String
For nIndex = 0 To MailMessage1.Recipients - 1
If Len(strRecipients) > 0 Then strRecipients = strRecipients & ", "
strRecipients = strRecipients & MailMessage1.Recipient(nIndex)
Next
See Also
Bcc Property, Cc
Property, Recipients Property,
To Property, ParseAddress Method
|