Subj : Problem with variables To : netscape.public.mozilla.jseng From : "Michael Putters" Date : Thu Nov 20 2003 01:09 pm Hi, I must be very very very bad at JavaScript, but here is some snippet : Application.onStartup = function() { var oArray = new Array( 5 ); // var i; for (i = 0; i != oArray.length; ++i) oArray[i] = i; for (i = 0; i != oArray.length; ++i) System.Print( 'oArray[{1}] = {2}\n', i, oArray[i] ); Algorithm.Transform( oArray, oArray, Square ); for (i = 0; i != oArray.length; ++i) System.Print( 'oArray[{1}] = {2}\n', i, oArray[i] ); } Now, just like that, it does execute perfectly... If I uncomment the "var i", it just silently stops at the variable declaration... why?? This snippet is the whole .js Thx .