-1

We are implementing marketing application with C#, In this application we need to send at least 1000 email to users,I have an email sender class.I have two important question:

  1. How can I send these emails without going to users's SPAM folder?
  2. Is there any design pattern for implementing this kind of class, I don't like to instantiate email class for every user,I would like to send email one by one, thread safe and without have performance impact on server.
Houshang.Karami
  • 291
  • 1
  • 3
  • 11
  • 3
    Whether or not an email message goes to a user's spam folder has nothing to do with how you code it. It's all in what's in the email text, who it's from, etc. If the client decides it's going to a spam folder, it's going to a spam folder. Getting email to not be flagged as spam is an excercise in marketing, not programming. – Beska Jul 12 '12 at 17:13
  • If you send email one by one why it will introduce thread issue? Wrap your email sending part in a class like (DeliveryEngine), then passing in the ToAddress and content etc. Send it one by one. – ValidfroM Jul 12 '12 at 17:15
  • 2
    See also [How to send 100,000 emails weekly?](http://stackoverflow.com/questions/3905734) . The simplest solution is to use a 3rd-party company and let them deal with it. Some such companies off their ownSMTP server, meaning your code will not change (with the obvious exception of the smtp config setting). See list by [sohtimsso](http://stackoverflow.com/a/3926061) in that same question. – Brian Jul 12 '12 at 17:22
  • I did find out Single tone design pattern is most use full to sending email through application.it prevents to have multi instantiate of class regarding this book "ASP.NET 3.5 Application Architecture and Design" page 134.for preventing to going Email to SPAM there are some practice,the important thing is we should have unsubscribtion link in email and the email body should have dynamic content . – Houshang.Karami Jul 13 '12 at 16:21

3 Answers3

1

As Beska says, its up to you to make the content of your email is not considered as spam. Don't set only the BCC field (i.e. the TO field should not be empty) and don't send just an image as the content (add some plain text too). See here for more tips: http://kb.mailchimp.com/article/how-spam-filters-think/

Surfbutler
  • 1,529
  • 2
  • 17
  • 38
0

My comment aside (where I say that getting emails to not show up as spam is not a matter of programming, but of marketing), there are a few things you have to have set up correctly in general for your emails to have a good chance of getting through at all, regardless of how you're sending them.

Jeff (yes, that Jeff) has a blog post about this that provides a nice checklist for you. Most of it isn't programming so much as server setup, but depending on your situtation, it might help you.

Beska
  • 12,445
  • 14
  • 77
  • 112
  • Thanks Beska and Brain,For first part of my question :our application sends email as over night task,How much depend on server? I would change application instead of server,I am looking for techniques that convince email service providers that my email is not SPAM. – Houshang.Karami Jul 12 '12 at 17:44
  • 1
    From an application perspective there is not much you can do. The blog post I listed mentions in step 2 how to digitally sign email, but that also requires setting things up on the mail server side. If you're not changing things on the mail server, there's not much you're going to be able to do from a programming perspective. Your time will be better spent looking at the email itself, to make sure it's not likely to be flagged for its content. – Beska Jul 12 '12 at 21:02
0

I did find out Single tone design pattern is most use full to sending emails through application.it prevents to have multi instantiate of class regarding this book "ASP.NET 3.5 Application Architecture and Design" page 134.for preventing to going Email to SPAM there are some other practice,the important thing is we should have unsubscribtion link in email and the email body should have dynamic content.there are some other techniques here: How to send emails and avoid them being classified as spam

Community
  • 1
  • 1
Houshang.Karami
  • 291
  • 1
  • 3
  • 11