Home > lang > error 
 fr de es it nl pl pt pt_BR mk sq ca hu tr ar fa vi ko ja ru zh zh_TW eo
Previous  Next  Edit  Rename  Undo  Refresh  Search  Administration  
Documentation
History
 
ERROR
ERROR AS Boolean

Returns TRUE if an error has happened.

Use it just after a TRY instruction to know if the executed instructions failed.

To get more information about the error, use the Error class.

The error flag is reset to FALSE when:
  • The RETURN instruction is executed.
  • A TRY instruction has been executed without any error.

Example

TRY KILL FileName
IF ERROR THEN PRINT "Cannot remove file. "; Error.Text

ERROR
ERROR Expression [ { ; | ;; | , } Expression ... ] [ { ; | ;; | , }  ]

Prints expressions to the standard error output, exactly like the PRINT instruction.

The standard output can be redirected by the ERROR TO statement.

See PRINT for more details about the syntax and the behaviour.

See also

Error Management  PRINT