'THE MAIL OBJECT
Dim ObjMail
Set ObjMail = Server.CreateObject("CDO.Message")
sendUrl="http://schemas.microsoft.com/cdo/configuration/sendusing"
smtpUrl="http://schemas.microsoft.com/cdo/configuration/smtpserver"
' Set the mail server configuration
Set objConfig=CreateObject("CDO.Configuration")
objConfig.Fields.Item(sendUrl)=cdoSendUsingPickup ' cdoSendUsingPort
objConfig.Fields.Item(smtpUrl)="relay-hosting.secureserver.net"
objConfig.Fields.Update
' Use the config object created above
Set objMail.Configuration=objConfig
objMail.From = "[email protected]"
objMail.To = "[email protected]"
objMail.Subject = "Mahesh Tutorials"
objMail.HTMLBody = a1
objMail.Send
Set objMail = Nothing
Set objConfig = Nothing
|