Hunny Software Library Reference

SmtpClient.Data Method 

Sends the DATA command.

[Visual Basic]
Public Sub Data()
[C#]
public void Data();

Remarks

The DATA command follows the RCPT command and tells the SMTP server to prepare to receive the current message. The message content of the current message follows the DATA command.

After the method returns, you should check the server's reply code, available as the ReplyCode property. A 354 reply code indicates that the server is ready to receive the message content.

Exceptions

Exception TypeCondition
ExceptionIf a network or protocol error occurs.

See Also

SmtpClient Class | Hunny.Mail Namespace | DATA command in the SMTP specification