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("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
theFlds("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "mail.servwise.com"
theFlds("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 60
theFlds("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
theFlds("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
theFlds("http://schemas.microsoft.com/cdo/configuration/sendusername")="name@email.com"
theFlds("http://schemas.microsoft.com/cdo/configuration/sendpassword") ="yourpassword"

theFlds.Update

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

objCDOMail.From = "sender@emaladdress.com"
objCDOMail.To = "recipient@emaladdress.com"
objCDOMail.Subject = "Email Subject"
objCDOMail.TextBody="Email Body"
objCDOMail.Send

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

You may also find the following useful http://www.w3schools.com/asp/asp_send_email.asp



  • 16 Users Found This Useful
Was this answer helpful?

Related Articles

What is an email "alias" or "forwarder" and what is it for? (Linux Hosting)

An email forwarder is an email address that exists only to forward emails to other addresses....

Am I allowed to send bulk emails (Newsletters, Promotions etc) and what are the limits

ServWise has a strict NO SPAM policy on sending of bulk email. Bulk email can only be sent to...

Updating Wordpress on our Windows Hosting

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

Can I view my site before the DNS has propagated?

Windows Hosting All websites are issued with an Instant alias based on the domain you supply...

How do I upload my website to your servers?

There are a number of ways to publish your website depending on if you are publishing to our...