Javascript Reference
Categories: Error

javascript Error Description

@March 15, 2008, 1:22 a.m.
ErrorFirefox/Netscape/NN 6 IE 5(Win) ECMA 3  

  

Browsers that implement try/catch exception handling automatically create an instance of the Error object whenever an error occurs during script processing. You can also create an Error object instance that you explicitly throw. The catch portion of the try/catch construction receives the Error object instance as a parameter, which scripts can examine to learn the details of the error, as exposed by the object's properties.

 
Properties
 
constructordescriptionfileNamelineNumber
messagenamenumberprototype
 
Methods
 
toString( )
 
Creating an Error Object
 
var myError = new Error("errorMessage");

Powered by Linode.