AXSoft SMTPSock - Error

Description

Occurs when there is an error.

Type

Event

Syntax

object_Error(Number As Long, Description As String, ServerResponse As String)

Parameter Type Description
Number Long A Long variable specifying the value error number.
Description String A string related to the error number.
ServerResponse String The response from the server. (Only if Error number = axsSMTPSockError_InvalidResponse)

 

Return Type

None

Remarks

Most of the errors generated, are returned by the winsock dll (wsock32.dll). Other errors, related to the SMTP server can be found in the ErrorConstants. After the Error event is fired, the control will automatically disconnect from the server. If the connection error is due to an "Invalid Server Response", then the ServerResponse variable will return the servers response. If the error was anything other than an "Invalid Server Response" then the ServerResponse variable will return an empty ("") string.

See Also: Connect, SendMail, ErrorConstants