referenceerror

o3d javascript uncaught reference error

hey, im new to javascript and am intersted in creating a small o3d script: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt; <html xmlns="http://www.w3.org/1999/xhtml"&gt; <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Test G...

How do we throw and catch a RangeError, ReferenceError, TypeError in JavaScript?

Hi all, I was wondering if any of you have tried catching errors such as RangeError, ReferenceError and TypeError using JavaScript's exception handling mechnism? For instance for RangeError: try { var anArray = new Array(-1); // an array length must be positive throw new RangeError("must be positive!") } catch (error) { ...