EmailMessage.To Property

The To property gets the primary recipients of the message.

Namespace: Microsoft.Exchange.Data.Transport.Email
Assembly: Microsoft.Exchange.Data.Transport (in microsoft.exchange.data.transport.dll)

Syntax

'Declaration
Public ReadOnly Property To As EmailRecipientCollection
public EmailRecipientCollection To { get; }
public:
property EmailRecipientCollection^ To {
    EmailRecipientCollection^ get ();
}
/** @property */
public EmailRecipientCollection get_To ()
public function get To () : EmailRecipientCollection

Remarks

Your agent might receive e-mail messages with zero recipients. This can happen if an application adds recipients to a message or in an agent that performs logging or diagnostics. When you implement your agent, check for the presence of recipients in the To property to avoid encountering an exception.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Platforms

Development Platforms

Windows XP Professional with Service Pack 2 (SP2), Windows Server 2003,

Target Platforms

Windows Server 2003