How to send email using ASP and CDOSYS

The following ASP script can be used to send email using CDOSYS on our servers.

Dim iConfig
Dim theFlds
Dim objCDOMail

Set iConfig = Server.CreateObject ("CDO.Configuration")
Set theFlds = iConfig.Fields

'Set and update fields properties
theFlds("") = 25
theFlds("") = ""
theFlds("") = 60
theFlds("") = 2
theFlds("") = 1
theFlds("") ="yourpassword"


'Create the e-mail server object
Set objCDOMail = Server.CreateObject("CDO.Message")
Set objCDOMail.Configuration = iConfig

objCDOMail.From = ""
objCDOMail.To = ""
objCDOMail.Subject = "Email Subject"
objCDOMail.TextBody="Email Body"

'Close the server mail object
Set objCDOMail = Nothing
Set theFlds= Nothing
Set iConfig = Nothing

You may also find the following useful

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Updating Wordpress on our Windows Hosting

If you have secured WordPress correctly on our Windows hosting then the vast majority of your...

Name server change and crossover traffic during propagation

During the change of Name servers, DNS is cached at all DNS servers until the TTL (time to live)...

Howto: Reduce Spam using SpamAssassin Bayesian filters in cPanel

Introduction While this article is intended to demonstrate how to train and use Bayesian filters...

What is an email "alias" and what is it for? (Windows Hosting)

What is an email alias and what is it for? (Windows Hosting) An email alias is an alternative...

Accessing mySQL remotely

Remote access to any of our database servers is provided solely for periodic maintenance, backups...