Subj : Re: dereferenced object To : netscape.public.mozilla.jseng From : "Sterling Bates" Date : Sat Apr 17 2004 06:07 pm "Thibaut" wrote in message news:c5s4pc$hon2@ripley.netscape.com... > What do you mean ?? > > This is what you told me : > >Use the JSClass.getProperty hook for childNodes' class. It should > >handle id parameters for which JSVAL_IS_INT(id) evaluates to true and > >JSVAL_TO_INT(id) is >= 0 and < the length of the array. I think what Brendan means is create a callback for JSClass.getProperty. In that callback, see if the id parameter is an int via JSVAL_IS_INT(id). If so, convert id to an int, then get that element from the array (if the array is JS only, use JS_GetElement). Like this (I think): idx = JSVAL_TO_INT(id); JS_GetElement(cx, myobj, idx, vp); Sterling .