Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles / Languages / C#

Sending an Email in C# with or without attachments: generic routine.

5.00/5 (3 votes)
3 Mar 2011CPOL 8.6K  
I would use Attachment [^] instead of MailAttachment[^]One should also use System.net.mail[^] instead of System.Web.Mail[^] which is now obsolete.
I would use Attachment [^] instead of MailAttachment[^]

One should also use System.net.mail[^] instead of System.Web.Mail[^] which is now obsolete.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)