Click or drag to resize

SmtpConnectAsync(String, CancellationToken) Method

Connects to SMTP server on port 587. Use ConnectSSL(String) when SSL/TLS connection is needed.

Namespace: Limilabs.Client.SMTP
Assembly: Mail (in Mail.dll) Version: 3.0.26106.1555
Syntax
public Task ConnectAsync(
	string host,
	CancellationToken cancel = default
)

Parameters

host  String
Host name or IP address.
cancel  CancellationToken  (Optional)
A cancellation token that can be used to signal the asynchronous operation should be canceled.

Return Value

Task
A task that represents the asynchronous connect operation.
Exceptions
ExceptionCondition
ServerExceptionDNS resolving error, connection error.
SmtpResponseExceptionInitial error response.
See Also