Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CDOSYS Configuration Question

Status
Not open for further replies.

Miked811

Programmer
Apr 17, 2005
61
CA
Hi,

I have this code below using CDOSYS. It works fine and perfect.

1) Im just wondering what is the "CDO.Configuration" for?

It is because, it uses the schemas.microsoft etc...I tried using without it and the code does not work.

2) Should it be always be schemas.microsoft as default? or
3) Can I use my host info as a substitute?...

Thanks a lot....



Dim objCDOSYSMail, objCDOSYSCon, HTML
'Create the e-mail server object
Set objCDOSYSMail = Server.CreateObject("CDO.Message")
Set objCDOSYSCon = Server.CreateObject "CDO.Configuration")
'Outgoing SMTP server
objCDOSYSCon.Fields " = "localhost"
objCDOSYSCon.Fields " = 25
objCDOSYSCon.Fields " = 2
objCDOSYSCon.Fields " = 60
objCDOSYSCon.Fields.Update

HTML = strMessage

' Update the CDOSYS Configuration
Set objCDOSYSMail.Configuration = objCDOSYSCon
'The mail is sent to the address declared in the form variable.
objCDOSYSMail.From = sEmailAddr
objCDOSYSMail.To = strEmailTo
objCDOSYSMail.Subject = sSubject
objCDOSYSMail.HTMLBody = HTML
objCDOSYSMail.Send

Set objCDOSYSCon = Nothing
Set objCDOSYSMail = Nothing
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top