next up previous contents index
Next: PAUSE Up: ON Previous: ON   Contents   Index


ON ERROR

        [SIC\]ON ERROR [Command]

    This command changes the current error recovery action.  By  default,  a
    PAUSE is automatically generated by any error during execution.

    This  can be changed and any other valid command line Command can be ac-
    tivated instead of PAUSE when an error occurs, using the command ON  ER-
    ROR  Command.  A  very  useful error recovery command for loops is NEXT,
    which enables skipping the remaining commands of the loop when something
    went wrong, and resumes the loop at for the following index value.

    Note  that  the  ON  ERROR command does not affect the behaviour on <^C>
    trapping, which always returns a PAUSE. The  ON ERROR  command  is  only
    valid within the procedure which declared it.


Gildas manager 2011-04-01