Join us on Facebook!

Sending mail in asp

by admin 1932 views 0 Comments and 0 Rections

Sending mail in asp through CDO is pretty simple. There are only few things to configure and you are ready to go! Here is the code for sending mail:

Set ObjSendMail = CreateObject("CDO.Message")

ObjSendMail.Configuration.Fields.Item ("") = 2
ObjSendMail.Configuration.Fields.Item ("") = mailServer
ObjSendMail.Configuration.Fields.Item ("") = 465
ObjSendMail.Configuration.Fields.Item ("") = True
ObjSendMail.Configuration.Fields.Item ("") = 60

ObjSendMail.Configuration.Fields.Item ("") = 1
ObjSendMail.Configuration.Fields.Item ("") = username
ObjSendMail.Configuration.Fields.Item ("") = password


ObjSendMail.To = toEmail
ObjSendMail.Subject = subJect
ObjSendMail.From = fromEmail

ObjSendMail.HTMLBody = Message

Set ObjSendMail = Nothing

mailServer: enter your mail server (smtp) address here. e.g:
username: your username/email address on that server.
: your password on that server.
toEmail: the email address to which you are sending mail.
subJect: subject of the email.
fromEmail: the email which the receiver will see in from field.
Message: message body of the email (can be html).

So thats all! Just configure these fields on you are ready to go!

More Posts in "Tutorials"


blog comments powered by Disqus

Feed Subscription

Get daily inboxed with latest news, reviews and tutorials. Signup now it's free :)

Planetmaks on Twitter

Follow PlanetMaks on Facebook

Recent Comments

Powered by Disqus


32Bit 64Bit 7 Admin Tool Admin Tools Admin-Tool Admin-Tools AdminTool Adobe Adware All-in-One Anti-Spyware Anti-Virus Apple Backup Tools Browser Browsers Changing Default Directory Codec Data Recovery Download Manager Downloads Drive Utilities Driver Drivers Firefox Flash Freeware Google Graphics Internet Tool Internet-Tool Messaging Microsoft Microsoft Tool Micsellonous Monitoring Multimedia Networking News NVidia Office Tool Office-Tool PC Suite Press Release Registry Samsung Security Shareware Software Softwares Tutorials Vista Windows Windows 7 Windows 8