Sends a mail message (
MimeMessage).
public void Send(
MimeMessage mail,
string sender,
string recipients
)
Public Sub Send( _
ByVal mail As MimeMessage, _
ByVal sender As String, _
ByVal recipients As String _
)
public:
void Send(
MimeMessage^ mail,
String^ sender,
String^ recipients
);
Parameters
- mail
- The message.
- sender
- Message sender address (can be null or empty).
- recipients
- The list of recipients (can be null).
Remarks
If the sender address argument is null (Nothing in Visual Basic), it is taken from the from the "Sender" header field
or from the first address in the "From" field if the "Sender" is missing.
If the sender address argument is empty string, it means null sender - same behavior as if "<>" would be specified.
If the recipients argument is null (Nothing in Visual Basic), it overrides the list of recipients contained in the message. If the recipients argument is null,
the list of recipients is extracted from "To", "Cc" and "Bcc" header fields.
The "Bcc" field is removed from message headers prior to sending.
Set the
AllowNullSender property to allow sending a mime message without a sender specified.