API Interface: .NET Framework Namespace Classes.
SWM is managed wrapper around CDOSYS – it only provides a subset of the functionality to send messages via SMTP, it does not do the same MIME parsing that CDOSYS can do.
SWM is replaced in the .NET Framework 2.0 by the System.Net.Mail namespace.
For whatever reason, a common mistake made when using SWM’s SmtpMail class is to set the the SmtpServer property using the Insert(string) method off the SmtpServer property (which is a string). The Insert method doesn’t set the SmtpServer property so it remains empty – what does is it this changes the send method from port to local pickup directory.
Debugging SWM issues is very systematic, there are only so many ways to send mail using SWM.
Problems usually arise from changes to the configuraiton of the SMTP server – either added authentication requirements, server names, or open availability.
Consider using System.Net.Mail or CDOSYS if you run into issues with System.Web.Mail since those are still supported and have broader capabilities.
How to send e-mail programmatically by using System.Web.Mail in Visual C# 2005 or in Visual C# .NET
Migrating from System.Web.Mail to System.Net.Mail
About: SMTP Sending APIs
About: Messaging APIs