Question

What it says on the tin.

Was it helpful?

Solution

According to the MSDN page on SmtpClient, the only purpose for SendAsync is to allow your current thread to continue processing instead of waiting for the transmission to process. The purpose of SendAsync isn't to allow you to send multiple messages at once, it's to allow you to continue processing while it sends the message. SendAsync and Send are both using the same pipeline, SendAsync just allows you to do other things while the message is sent.

OTHER TIPS

According to MSDN:

After calling SendAsync, you must wait for the e-mail transmission to complete before attempting to send another e-mail message using Send or SendAsync.

So you could reuse the same instance but you must wait for the first mail to be sent.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top