$ErrMsg: Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (Mlarocca moved page $ERRMSG to $Errmsg: Lower case change)
m (Dme moved page $Errmsg to $ErrMsg: Sorry my eyes are way tooold)
 
(5 intermediate revisions by 3 users not shown)
Line 1: Line 1:
<p>The <var>$ErrMsg</var> function returns a string containing the prefix and text of the last counting error message or request cancellation message received by the user. </p>
__NOTOC__
<p>
The <var>$Errmsg</var> function returns a string containing the prefix and text of the last [[Introduction to User Language#Counting errors|counting error]] message or request cancellation message received by the user. </p>
<p>A null value is returned if no counting error or request cancellation message has been received since:</p>
<p>A null value is returned if no counting error or request cancellation message has been received since:</p>
<ul>
<ul>
<li>The beginning of the user's <var class="product">Model&nbsp;204</var> session</li>
<li>The beginning of the user's <var class="product">Model&nbsp;204</var> session</li>
</li>
<li>The last call to the <var>[[$ERRCLR]]</var> function.</li>
<li>The last call to the <var>[[$ErrClr]]</var> function.</li>
</li>
<li>Processing a <var class="product">SOUL</var> <var>Open</var> statement</li>                                                 
<li>Processing a <var class="product">SOUL</var> <var>Open</var> statement</li>
</li>
</ul>
</ul>
<p>Refer to the Rocket <var class="product">Model&nbsp;204</var> Messages Manual for more information on counting messages. This function takes no arguments.             </p>
<b>Example</b>
==Syntax==
<p>A sample <var>$ErrMsg</var> function with an <var>On Error</var> unit follows. To learn about <var>On Error</var> units, see [[Subroutines#ON units|ON units]].</p>
This function takes no arguments.
==Usage notes==
<p>
The maximum length of the returned string is determined by the setting of the <var>[[ERRMSGL parameter|ERRMSGL]]</var> parameter. That parameter defaults to 80, which means a maximum of 79 characters are returned, but <var>ERRMSGL</var> can be set as high as 256, which means up to 255 characters would be returned. </p>
==Example==
<p>
A sample <var>$Errmsg</var> function with an <var>On Error</var> unit follows. To learn about <var>On Error</var> units, see [[Subroutines#ON units|ON units]].</p>
<p class="code">begin
<p class="code">begin
error.proc: on error
error.proc: on error
Line 28: Line 37:
end
end
</p>
</p>
<p>The maximum length of the returned string is determined by the setting of the <var>[[ERRMSGL parameter|ERRMSGL]]</var> parameter. That parameter defaults to 80 which means a maximum of 79 characters are returned, but <var>ERRMSGL</var> can be set as high as 256 which means up to 255 characters would be returned.
==See also==
==See also==
<ul>
<ul>
<li>the [[IFGERR IFAM function]]
<li><var>IFGERR</var> <var class="product">[[Media:M204_HLIReference_V75.pdf|IFAM]]</var> function. </li>
<li><var>[[$FSTERR]]</var>, which returns the <b>first</b> counting error message.
<li><var>[[$Fsterr]]</var>, which returns the <b>first</b> counting error message. </li>
<li>The <var>[[ErrMsgL parameter|ERRMSGL]]</var> parameter, which determines the length of errors returned by <var>$ErrMsg</var> and <var>$FstErr</var>.
<li>The <var>[[ERRMSGL parameter|ERRMSGL]]</var> parameter, which determines the length of errors returned by <var>$Errmsg</var> and <var>$Fsterr</var>.
</ul>
</ul>
[[Category:SOUL $functions]]
[[Category:SOUL $functions]]

Latest revision as of 17:44, 8 November 2019

The $Errmsg function returns a string containing the prefix and text of the last counting error message or request cancellation message received by the user.

A null value is returned if no counting error or request cancellation message has been received since:

  • The beginning of the user's Model 204 session
  • The last call to the $ErrClr function.
  • Processing a SOUL Open statement

Syntax

This function takes no arguments.

Usage notes

The maximum length of the returned string is determined by the setting of the ERRMSGL parameter. That parameter defaults to 80, which means a maximum of 79 characters are returned, but ERRMSGL can be set as high as 256, which means up to 255 characters would be returned.

Example

A sample $Errmsg function with an On Error unit follows. To learn about On Error units, see ON units.

begin error.proc: on error print 'The request is ending' print 'The last error message received was:' print $errMsg end on get.recs: find all records for which agent = casola end find for each record in get.recs . . . end for end

See also

  • IFGERR IFAM function.
  • $Fsterr, which returns the first counting error message.
  • The ERRMSGL parameter, which determines the length of errors returned by $Errmsg and $Fsterr.