Loop through the Recipients collection and check the Type property, it
will be olTo for anyone in the To field.
--JP
On Jan 29, 10:43*am, Damon Longworth
<DamonLongwo...@discussions.microsoft.com> wrote:
> Hello
>
> I am trying to set add an address to the BCC field when a message is sentto
> specific address. I have found some code to get the BCC, but do not know how
> to find the address in the TO field.
>
> How can I get the TO address into a string?
>
> Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
> * * Dim objRec As Recipient
> * * Set objRec = Item.Recipients.Add("MyAddr...@domain.com")
> * * objRec.Type = olBCC
> * * objRec.Resolve
> * * Set objRec = Nothing
> End Sub
|