Connecting to MailEnable with vb.net

Discussion for developers using MailEnable.
Post Reply
MWilson02
Posts: 3
Joined: Tue Mar 09, 2010 11:28 am

Connecting to MailEnable with vb.net

Post by MWilson02 »

Hello,

I am trying to send an email by using my MailEnable email account but this code produces the following exception:

"Syntax error, command unrecognized. The server response was: Welcome to MailEnable POP3 Server"

If I use port 8080, I get a timed out exception.


Private Sub SendWebMail()
Dim myServer As New SmtpClient("listserv.company.com", 110)

myServer.Credentials = New System.Net.NetworkCredential("Alert@mmail.company.com", "Password369")

Dim myMessage As New MailMessage(from:="Alert@mmail.company.com", to:="M.Wilson@company.com")
myMessage.Body = "this is a test"
myMessage.Subject = "from vb"
myServer.EnableSsl = True
myMessage.To.Add("M.Wilson@company.com")
myServer.Send(myMessage)

End Sub

Any help is greatly appreciated.

thanks,
M. Wilson

Post Reply