Using the SmtpMail Class to Add E-mail Functionality to an Application

Visual Basic .NET’s SmtpMail class is provided to allow your applications to send e-mail messages. It utilizes the Simple Mail Transfer Protocol (SMTP), which is the Internet standard for sending e-mail messages. The SmtpMail class uses the SMTP service built into Windows 2000 (and later versions) to pass a MailMessage object to an SMTP server, which in turn forwards the message to the intended recipient.

Sending Mail Messages with the MailMessage Class

The workhorse of the SmtpMail class is the MailMessage class, which provides the methods and properties necessary to send an e-mail message. To send an e-mail message, you create an instance of the MailMessage class, set ...

Get Special Edition Using Microsoft® Visual Basic® .NET now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.