The throw, try and catch statements

Domain Hosting image
Web Hosting
Dedicated server
ssl certificate
Web Design image
Email
An exception is an abnormal condition that arises in a code sequence at run time. In other words an exception is a run time error. Your script generates an exception at runtime so that it may be handled. The block of codes which resolves the exception is known as an exception handler. Exceptions are handled by the try and catch statements. The syntax for try catch statements are:

try(
statements where exceptions may be thrown
catch (exceptionvariable){
statements handling the exception

The try statement contains the statements where exceptions may arise during the run time. When an exception is thrown during the execution of the statements contained within the try block the exception variable is assigned an error object which identifies the exception and the control passes to the catch block.



Domain Name Search

www.


Copyright (C) 2007. Web Domain design hosting. All rights reserved.