TRY and catch block. The code which might produce some EXCEPTIONS is PLACED inside the try block and then the catch block is written to catch the error that is produced. The error message or any other PROCESSING can be DONE in catch block if the error is produced.