Connecting to MailEnable with vb.net

MWilson02
Posts: 3
Joined: Tue Mar 09, 2010 11:28 am

Connecting to MailEnable with vb.net

Postby MWilson02 » Tue Mar 09, 2010 11:33 am

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

Who is online

Users browsing this forum: No registered users and 1 guest