"
 
 
 
ASP.NET (snapshot 2017) Microsoft documentation and samples

[How Do I:] Implement Error Handling when Sending Email with ASP.NET

by Chris Pels

Chris Pels shows how to implement error handling when sending an email with ASP.NET. He creates an ASP.NET web page to send email, shows how to configure <mailSettings> in the web.config file, describes the System.Net.Mail class and how it’s used to create and send email messages. He then adds error handling using System.Net.Mail exception classes, which provide information about errors that can occur when sending email, and reviews the SmtpStatusCode enumeration, which provides a list of possible outcomes when sending an email with the SmtpClient. Finally, he sends a test email that raises an exception and reviews the error handling information in the Visual Studio debugger.

▶ Watch video (24 minutes)





Comments ( )
<00>  <01>  <02>  <03>  <04>  <05>  <06>  <07>  <08>  <09>  <10>  <11>  <12>  <13>  <14>  <15>  <16>  <17>  <18>  <19>  <20>  <21>  <22>  <23
Link to this page: //www.vb-net.com/AspNet-DocAndSamples-2017/aspnet/web-forms/videos/how-do-i/how-do-i-implement-error-handling-when-sending-email-with-aspnet.htm
<SITEMAP>  <MVC>  <ASP>  <NET>  <DATA>  <KIOSK>  <FLEX>  <SQL>  <NOTES>  <LINUX>  <MONO>  <FREEWARE>  <DOCS>  <ENG>  <CHAT ME>  <ABOUT ME>  < THANKS ME>