![]() ![]() ![]() ObjMail.Subject = "My first ASP.NET email" ' The priority of the message - it can be MailPriority.High, ObjMail.Bcc = The format of the message - it can be MailFormat.Text ObjMail.Cc = The email address of the Bcc recipient ObjMail.To = The email address of the Cc recipient ObjMail.From = The email address of the recipient Next, we have to set all the properties of the objMail object: ' The email address of the sender To build our email message we need to create an instance of this class: Dim objMail As New MailMessage() ![]() The MailMessage class provides properties and methods for constructing an email message. In order to use them, we will need to import the namespace like this: We are going to use the SmtpMail and MailMessage classes, which belong to the namespace. Import the namespace, and create instances of required classes This article presumes that you have a basic understanding of how. NET framework makes the task of sending email from a Web page unbelievably easy and I’ll show you how to do it in a matter of minutes. Of course there are many more situations where it’s appropriate to send email from your Web applications, and it’s up to you to determine exactly how and where you’re going to implement this functionality. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |