Send mass emails with ASP.Net

asp.net, c#

Solution

Edit per Troy's comment.

You should use an external process to send the emails. If your email list grows to a few mere hundred you'll run into timeouts in no time. Once you get into the lists that are a thousand or a million records long you can forget about any workable solution using ASP.Net alone.

I've actually developed a windows service that handles sending out mass emails. Basically in ASP.Net I create a campaign and a batch job in various db records and then insert a list of recipients as well. Once the job has been fully written to the db it's status is changed so that the Windows Service knows it can come along and start processing the job. Then the ASP.Net site can look at the records at any time to determine how far along the service has gotten.

Problem

What is the best way to send mass emails using ASP.Net? For example a site administrator needs to send email (e.g. a newsletter) to all of his site’s users. What is the best way to do this with ASP.Net 3.5 and C#?

Original source