GetReplyCode (Email function): Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
|||
(9 intermediate revisions by 3 users not shown) | |||
Line 3: | Line 3: | ||
==Syntax== | ==Syntax== | ||
{{Template:Email:GetReplyCode syntax}} | {{Template:Email:GetReplyCode syntax}} | ||
===Syntax terms=== | ===Syntax terms=== | ||
<table class="syntaxTable"> | <table class="syntaxTable"> | ||
<tr><th>% | <tr><th>%number</th> | ||
<td>A string, longstring, or numeric variable to contain the numeric | <td>A string, longstring, or numeric variable to contain the numeric return code indicating the result of the method invocation. The types of return codes are described below. </td></tr> | ||
return code indicating the result of the method invocation. | |||
The types of return codes are described below. | <tr><th>email</th> | ||
</td></tr> | <td>An <var>Email</var> object.</td></tr> | ||
<tr><th> | </table> | ||
<td> | |||
</td></tr></table> | |||
==Usage notes== | ==Usage notes== | ||
<ul> | <ul> | ||
<li>The <var>GetReplyCode</var> return code can be zero, negative, or positive: | <li>The <var>GetReplyCode</var> return code can be zero, negative, or positive: | ||
<ul> | <ul> | ||
<li>Zero, if the <var>[[Mail (Email function)|Mail]]</var> method | <li>Zero, if the <var>[[Mail (Email function)|Mail]]</var> method | ||
has not yet been invoked for the | has not yet been invoked for <var class="term">email</var> (the method object). | ||
<li>Negative, if the TCP connection to the SMTP server host cannot be established. | <li>Negative, if the TCP connection to the SMTP server host cannot be established. | ||
These [[#Network communication error codes|"Network communication error codes"]] are documented below. | These [[#Network communication error codes|"Network communication error codes"]] are documented below. | ||
<li>Positive, if the TCP connection is established. | <li>Positive, if the TCP connection is established. | ||
These [[#SMTP server return codes|"SMTP server return codes"]] are documented below. | These [[#SMTP server return codes|"SMTP server return codes"]] are documented below. | ||
<li><var>[[GetReplyText (Email | |||
<li><var>[[GetReplyText (Email function)|GetReplyText]]</var> | |||
returns the text message associated with the message number. | returns the text message associated with the message number. | ||
</ul> | </ul> | ||
</ul> | </ul> | ||
<div id="commerr"></div> | |||
===Network communication error codes=== | ===Network communication error codes=== | ||
If the socket connection attempt fails, the possible error | If the socket connection attempt fails, the possible error | ||
code are shown below: | code are shown below: | ||
<table> | <table class="thJustBold"> | ||
<tr><th>Code</th> | <tr class="head"><th>Code</th> | ||
<th>Meaning</th> | <th>Meaning</th> | ||
<tr><th>n > 1</th> | <tr><th>n > 1</th> | ||
<td>Socket number for the successfully connected socket. | <td>Socket number for the successfully connected socket. | ||
The returned value was the next available unused socket number.</td></tr> | The returned value was the next available unused socket number.</td></tr> | ||
<tr><th>-100</th> | <tr><th>-100</th> | ||
<td>No free socket numbers for user.</td></tr> | <td>No free socket numbers for user.</td></tr> | ||
<tr><th>-101</th> | <tr><th>-101</th> | ||
<td>Remote host name or IP address missing or mismatch with | <td>Remote host name or IP address missing or mismatch with | ||
CLSOCK port definition.</td></tr> | <var>[[JANUS DEFINE#type|CLSOCK]]</var> port definition.</td></tr> | ||
<tr><th>-102</th> | <tr><th>-102</th> | ||
<td>Remote port number missing or mismatch with CLSOCK | <td>Remote port number missing or mismatch with <var>CLSOCK</var> | ||
port definition.</td></tr> | port definition.</td></tr> | ||
<tr><th>-103</th> | <tr><th>-103</th> | ||
<td>CLSOCK port not defined or not started.</td></tr> | <td><var>CLSOCK</var> port not defined or not started.</td></tr> | ||
<tr><th>-104</th> | <tr><th>-104</th> | ||
<td>All ports on specified CLSOCK port are busy.</td></tr> | <td>All ports on specified <var>CLSOCK</var> port are busy.</td></tr> | ||
<tr><th>-105</th> | <tr><th>-105</th> | ||
<td>Insufficient virtual storage.</td></tr> | <td>Insufficient virtual storage.</td></tr> | ||
<tr><th>-106</th> | <tr><th>-106</th> | ||
<td>Maximum connections exceeded.</td></tr> | <td>Maximum connections exceeded.</td></tr> | ||
<tr><th>-107</th> | <tr><th>-107</th> | ||
<td>Couldn't resolve remote host.</td></tr> | <td>Couldn't resolve remote host.</td></tr> | ||
<tr><th>-108</th> | <tr><th>-108</th> | ||
<td>Remote port not responding.</td></tr> | <td>Remote port not responding.</td></tr> | ||
<tr><th>-109</th> | <tr><th>-109</th> | ||
<td>Already have SOCKPMAX sockets open on this CLSOCK port.</td></tr> | <td>Already have <var>[[SOCKPMAX (JANUS DEFINE parameter)|SOCKPMAX]]</var> sockets open on this <var>CLSOCK</var> port.</td></tr> | ||
<tr><th>-110</th> | <tr><th>-110</th> | ||
<td>SSL | <td>Server/client SSL setting mismatch: either the server port is using SSL while the client socket port is not, or vice versa.</td></tr> | ||
<tr><th>-111</th> | <tr><th>-111</th> | ||
<td>SSL handshake error.</td></tr> | <td>SSL handshake error.</td></tr> | ||
<tr><th>-112</th> | <tr><th>-112</th> | ||
<td>Access to CLSOCK port not enabled by ALLOW rule.</td></tr> | <td>Access to <var>CLSOCK</var> port not enabled by <var>[[JANUS WEB ALLOW|ALLOW]]</var> rule.</td></tr> | ||
<tr><th>-149</th> | <tr><th>-149</th> | ||
<td>Other error during connection.</td></tr> | <td>Other error during connection.</td></tr> | ||
</table> | </table> | ||
===SMTP server return codes=== | ===SMTP server return codes=== | ||
These return codes are the response from the SMTP server, | These return codes are the response from the SMTP server, and they are generally categorized as follows: | ||
and they are generally categorized as follows: | <table class="thJustBold"> | ||
<table> | <tr class="head"><th>Code</th> | ||
<tr><th>Code</th> | |||
<th>Meaning</th> | <th>Meaning</th> | ||
<tr><th>100-199 | <tr><th>100-199 | ||
</th><td>Positive preliminary reply | </th><td>Positive preliminary reply | ||
</td></tr> | </td></tr> | ||
<tr><th>200-299 | <tr><th>200-299 | ||
</th><td>Positive completion reply | </th><td>Positive completion reply | ||
</td></tr> | </td></tr> | ||
<tr><th>300-399 | <tr><th>300-399 | ||
</th><td>Positive intermediate reply | </th><td>Positive intermediate reply | ||
</td></tr> | </td></tr> | ||
<tr><th>400-499 | <tr><th>400-499 | ||
</th><td>Transient negative completion reply | </th><td>Transient negative completion reply | ||
</td></tr> | </td></tr> | ||
<tr><th>500-599 | <tr><th>500-599 | ||
</th><td>Permanent negative completion reply | </th><td>Permanent negative completion reply | ||
</td></tr></table> | </td></tr> | ||
</table> | |||
==See also== | ==See also== | ||
{{Template:Email:GetReplyCode footer}} | {{Template:Email:GetReplyCode footer}} |
Latest revision as of 23:09, 2 September 2014
Retrieve the last numeric reply code (Email class)
Syntax
%number = email:GetReplyCode
Syntax terms
%number | A string, longstring, or numeric variable to contain the numeric return code indicating the result of the method invocation. The types of return codes are described below. |
---|---|
An Email object. |
Usage notes
- The GetReplyCode return code can be zero, negative, or positive:
- Zero, if the Mail method has not yet been invoked for email (the method object).
- Negative, if the TCP connection to the SMTP server host cannot be established. These "Network communication error codes" are documented below.
- Positive, if the TCP connection is established. These "SMTP server return codes" are documented below.
- GetReplyText returns the text message associated with the message number.
Network communication error codes
If the socket connection attempt fails, the possible error code are shown below:
Code | Meaning |
---|---|
n > 1 | Socket number for the successfully connected socket. The returned value was the next available unused socket number. |
-100 | No free socket numbers for user. |
-101 | Remote host name or IP address missing or mismatch with CLSOCK port definition. |
-102 | Remote port number missing or mismatch with CLSOCK port definition. |
-103 | CLSOCK port not defined or not started. |
-104 | All ports on specified CLSOCK port are busy. |
-105 | Insufficient virtual storage. |
-106 | Maximum connections exceeded. |
-107 | Couldn't resolve remote host. |
-108 | Remote port not responding. |
-109 | Already have SOCKPMAX sockets open on this CLSOCK port. |
-110 | Server/client SSL setting mismatch: either the server port is using SSL while the client socket port is not, or vice versa. |
-111 | SSL handshake error. |
-112 | Access to CLSOCK port not enabled by ALLOW rule. |
-149 | Other error during connection. |
SMTP server return codes
These return codes are the response from the SMTP server, and they are generally categorized as follows:
Code | Meaning |
---|---|
100-199 | Positive preliminary reply |
200-299 | Positive completion reply |
300-399 | Positive intermediate reply |
400-499 | Transient negative completion reply |
500-599 | Permanent negative completion reply |