In this section, we’ll talk about two ways to send e-mail messages. The first is simple, the second is more complicated but offers additional flexibility.
Creating an e-mail is quite simple using the SmptMail object. Because the Send() method of the object is overloaded, it can take several variations of information. You can send an e-mail in two basic ways: pass all the components of an e-mail to the object separately, or pass it a MailMessage object. First look at passing separate components of an e-mail to the Send method by studying Listing 15.1.
Let’s first look at a VB example.
<%@ Import Namespace=”System.Web.Mail” %> <HTML> <head> ...