Products Downloads


French version


 

 

ADELIA

      

      

      

      

(I)

 

 

 

 

 

Section for use

VERIFICATION

 

Syntax

ERROR

 

Description

This instruction is used to send a halting error message.

Consequences when sending the message:

    • The field which is after the error message declaration is set to reverse image and the error message displayed; the verification process is halted.

    • The re-display of the transaction is automatically done by Adelia.

    • After reverse image and error display are performed, the cursor is placed on the variable mentioned by the error message declaration; see the PREPARE_MSG (Adelia context) instruction.

Note: It is not necessary to use an error message subfile with this instruction. However, you may use an error message subfile with the ERROR instruction if you need to put variables in the message.

 

Important note: The differences between ERROR and ANOMALY are:

    • ERROR is an immediate halting error; it stops the verification process.
    • ANOMALY does not stop the verification process and loads all error messages in the "Error message subfile".
    • ERROR does not require an error message subfile; ANOMALY does.


Example

PREPARE_MSG 0011 Z_SALES_AMOUNT

IF Z_SALES_AMOUNT = 0

ERROR

END

*

PREPARE_MSG 0013 Z_PAYMENT_CODE

CHAIN PAYMENTS

IF   PAYMENTS DOES_NOT_EXIST

INIT_MSG Z_PAYMENT_CODE

ERROR

END

If sales amount is equal to zero and payment code is not correct, then only message 0011 is displayed; sales amount screen field is reversed; cursor is on it; if sales amount is different from zero and payment code is not correct, then message 0013 is displayed; payment code screen field is reversed; cursor is on it.

 

See also the list of 4GL instructions by topic

↑ Top of page

  • Aucune étiquette