E Error object (Object/core) -myError = new (Simple web server)

E Error object (Object/core) -myError = new Error() -myError = new Error(aNumber) JavaScript syntax: -myError = new Error(aNumber, aText) aNumber An error number Argument list: aText A text describing the error Object properties: constructor, description, message, name, number, prototype Object methods: toString() This object is provided to create custom error codes for your application. The ECMA standard (edition 3) describes them as objects that are thrown as exceptions when a run-time error occurs. These objects are passed as the first argument of the catch() function in a try … catch structure where you can inspect them and deal with the error. Example code: // Force an error condition myError = new Error(100, “My user defined error text”) try { throw myError; } catch(anErr) { confirm(anErr.description); } finally { alert(”Sorted”); } See also: Property JavaScript JScript N IE Opera NES ECMA Notes constructor 1.5 + 5.0 + 6.0 + 5.0 + 3 + DontEnum. description 5.0 + 5.0 + Warning message 1.5 + 5.5 + 6.0 + 5.5 + 3 + Warning name 1.5 + 5.5 + 6.0 + 5.5 + 3 + - number 1.5 + 5.0 + 6.0 + 5.0 + - prototype 1.5 + 5.0 + 6.0 + 5.0 + 3.0 + 2.0 + 3 + ReadOnly, DontDelete, DontEnum. catch( … ), EvalError object, RangeError object, ReferenceError object, SyntaxError object, throw, try … catch … finally, TypeError object, URIError object
Note: If you are looking for best quality webspace to host and run your tomcat application check Vision personal web hosting services

Leave a Reply