app79 common wisdom, helpful code and useful apps

11Aug/090

IE Stack Overflow Javascript Fix

Fix for calling the same function a few times in an almost infinite loop using the onchange event and getting a stack overflow at line 0 or any other line error in Internet Explorer:

function MyFunction(currentTextBox, nextTextBox)

{

//magic code in here

//when magic finished, call next magic spell

setTimeout(function(){FireNextBox(nextTextBox},1);

}

function FireNextBox(nextTextBox)

{

nextTextBox.onchange();

}

//for last textbox in loop

function FinalFunction()

{

return;

//the end

}

The above scenario assumes the onchange event calls ‘MyFunction’ and there is a return function available, ‘FinalFunction’ that is called by the onchange event of the last textbox in this loop. Using setTimeout is necessary in Internet Explorer, otherwise it will throw a stack overflow error, works fine in Firefox with and without the setTimeout.

30Mar/090

Why can’t my Mii be happy I’m a loser? – Nintendo’s Tech Support Forums

Trying out Windows Live Writer (Yahoo it if you want to download it). Found this awesome thread on Nintendo’s tech support forum regarding why your mii on your wii can’t be permanently happy:sad-mii

Turn off sad face on Wii sports - Wii Games - Nintendo's Tech Support Forums

(Windows Live Writer and my findings are uncorrelated though there is causation.)

Recent Posts

Archives

Blogroll

Categories

Tags

cartoon corporate email first funny how to internet internet explorer javascript linux computers os management office marshmallow theory onchange sadness singularity no theory robot stack overflow tech support tutorial upside down computer video youtube