One of the key aspects of programming is understanding how to handle exceptions. An exception is a problem that prevents the continuation of the current method or scope. Itís important to distinguish an exceptional condition from a normal problem, in which you have enough information in the current context to somehow cope with the difficulty. With an exception, you cannot continue processing because you lack the information necessary to address the problem in its current context. The only recourse
Updated 11-30-2011 at 03:19 AM by Java Exception
Following on from our previous tip on exceptions, in this tip we will look at catching an exception. One of the key concepts to understand is the concept of a guarded region. It is a section of code that might produce exceptions and is followed by the code to handle a particular exception. They are often grouped into all the possible exceptions for a particular method or piece of code.
The try block
The first part of the region is the try block. This is when youíre inside a