R
Rob R. Ainscough
I'm using MailMessage class from System.Web.Mail
My code works fine when I specify an SMTP mail server (i.e.
mail.speakeasy.net), but when I change that to another SMTP mail server that
requires authentication I get the above error message. There doesn't appear
to be any support in the MailMessage class that works with authentication??
Am I screwed? Any work arounds? Any alternates? The policy of the SMTP
mail server by hosting company is such that Authentication is REQUIRED so
there is no chance I can get that changed on the Mail Server.
Dim ConfirmationMessage As New MailMessage
With ConfirmationMessage
.To = _Customer.EMail
.Cc = Site.FacilityEMail
.From = Site.EMailServerConfirmationAddy
.Subject = Site.SiteName
.Priority = MailPriority.Normal
.Body = "Welcome Message"
End With
Try
SmtpMail.SmtpServer = Site.EMailServer
SmtpMail.Send(ConfirmationMessage)
Catch ex As Exception
' Show Error
End Try
Any suggestions, Rob.
My code works fine when I specify an SMTP mail server (i.e.
mail.speakeasy.net), but when I change that to another SMTP mail server that
requires authentication I get the above error message. There doesn't appear
to be any support in the MailMessage class that works with authentication??
Am I screwed? Any work arounds? Any alternates? The policy of the SMTP
mail server by hosting company is such that Authentication is REQUIRED so
there is no chance I can get that changed on the Mail Server.
Dim ConfirmationMessage As New MailMessage
With ConfirmationMessage
.To = _Customer.EMail
.Cc = Site.FacilityEMail
.From = Site.EMailServerConfirmationAddy
.Subject = Site.SiteName
.Priority = MailPriority.Normal
.Body = "Welcome Message"
End With
Try
SmtpMail.SmtpServer = Site.EMailServer
SmtpMail.Send(ConfirmationMessage)
Catch ex As Exception
' Show Error
End Try
Any suggestions, Rob.