Can't send an email in a .net 2.0 page

Hi all,

I'm trying to send an email via a asp.net 2.0 page but I'm getting the following error:

System.Net.Mail.SmtpException: Error in processing. The server response was: http://www.spamhaus.org/query/bl?ip=72.78.113.169

I've tried numerous code examples on both the internet and these forums but always get the same result.

Here's my latest example. Can anyone tell me what I'm doing wrong?

Dim Message As MailMessage = New MailMessage()
Dim Smtp As New SmtpClient()
Dim SmtpUser As New System.Net.NetworkCredential()
'-- Build Message
Message.From = New MailAddress("[email protected]")
Message.To.Add(New MailAddress("[email protected]"))
Message.IsBodyHtml = False
Message.Subject = "Email sent from the contact page!"
Message.Body = txtMessage.Text
'-- Define Authenticated User
SmtpUser.UserName = "testid"
SmtpUser.Password = "testpassword"
SmtpUser.Domain = "mail.sharedhorizons.net"
'-- Send Message
Smtp.UseDefaultCredentials = False
Smtp.Credentials = SmtpUser
Smtp.Host = "mail.sharedhorizons.net"
Smtp.DeliveryMethod = SmtpDeliveryMethod.Network
Smtp.Send(Message)
 
That means it can't send because that verizon IP is in the spamhaus blacklist, but that IP is NOT one of ours at all, so I am not sure where you are getting such a message on our servers.
 
Back
Top