SMTP Authentication
Dim objSMTP, strTemp ' Create mailer component Set objSMTP = CreateObject("MailBee.SMTP") ' Unlock SMTP component objSMTP.LicenseKey = "put your license key here" ' Set SMTP server name objSMTP.ServerName = "mail.server.com" ' Use LOGIN Authentication method (insecure, but ' supported by nearly all SMTP servers) objSMTP.AuthMethod = 2 ' Set authentication credentials objSMTP.UserName = "jdoe" objSMTP.Password = "secret" ' Set message properties objSMTP.FromAddr = "sender@firstdomain.com" objSMTP.ToAddr = "recipient@seconddomain.com" objSMTP.Subject = "Test" objSMTP.BodyText = "Body of the test message" ' Try to send message If objSMTP.Send Then MsgBox "Sent successfully" Else MsgBox "Error #" & objSMTP.ErrCode & ", " & objSMTP.ErrDesc End If
Dim objSMTP, strTemp ' Create mailer component Set objSMTP = Server.CreateObject("MailBee.SMTP") ' Unlock SMTP component objSMTP.LicenseKey = "put your license key here" ' Set SMTP server name objSMTP.ServerName = "mail.server.com" ' Use LOGIN Authentication method (insecure, but ' supported by nearly all SMTP servers) objSMTP.AuthMethod = 2 ' Set authentication credentials objSMTP.UserName = "jdoe" objSMTP.Password = "secret" ' Set message properties objSMTP.FromAddr = "sender@firstdomain.com" objSMTP.ToAddr = "recipient@seconddomain.com" objSMTP.Subject = "Test" objSMTP.BodyText = "Body of the test message" ' Try to send message If objSMTP.Send Then Response.Write "Sent successfully" Else Response.Write "Error #" & objSMTP.ErrCode & ", " & objSMTP.ErrDesc End IfSee Also: