MSIR.0975: Difference between revisions

From m204wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 8: Line 8:
<li> A Catch statement specifies a base class followed by its extension class, which isn't allowed. The Catch statement can specify a base class, and extension class, or extension followed by the base class being extended, but not base followed by extension. In this case the following messages is produced:
<li> A Catch statement specifies a base class followed by its extension class, which isn't allowed. The Catch statement can specify a base class, and extension class, or extension followed by the base class being extended, but not base followed by extension. In this case the following messages is produced:
<p class="code>MSIR.0975: CATCH invalid -- extension class after base class</p></li>
<p class="code>MSIR.0975: CATCH invalid -- extension class after base class</p></li>
<li>The only valid syntactical words that can follow an exception class name on a Catch statement are 'To', to specify the object to which a caught exception is being saved, and 'And' to introduce an additional exception class to catch. Any other words will be rejected with the following message:
<p class="code>MSIR.0975: CATCH invalid -- invalid word after class name</p></li>
</ul>  
</ul>  
{{Template:MSIR.0975 footer}}
{{Template:MSIR.0975 footer}}

Revision as of 13:42, 7 June 2018

MSIR.0975  CATCH invalid -- token

A Catch statement or block was coded in an invalid context. The following examples are amongst the texts that might be displayed with this message:

  • The Catch statement or block is not located within a valid Try block, as it must be, in which case the following message is produced:

    MSIR.0975: CATCH invalid -- not inside a Try block

  • A Catch statement specifies a base class followed by its extension class, which isn't allowed. The Catch statement can specify a base class, and extension class, or extension followed by the base class being extended, but not base followed by extension. In this case the following messages is produced:

    MSIR.0975: CATCH invalid -- extension class after base class

  • The only valid syntactical words that can follow an exception class name on a Catch statement are 'To', to specify the object to which a caught exception is being saved, and 'And' to introduce an additional exception class to catch. Any other words will be rejected with the following message:

    MSIR.0975: CATCH invalid -- invalid word after class name

Message attributes:

RETCODEO=0Sets online return code
RETCODEB=4Sets batch (single user) return code
CLASS=EError class; the message can be suppressed with the X'04' bit setting of the MSGCTL parameter
AUDITERWrites the message with line type ER to the audit trail
COUNTIncrements the error count (ERCNT) parameter
ECHODisplays the line that caused the error

Back to list of messages