Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Stack overflow

Status
Not open for further replies.

tiramisu01

Programmer
Feb 11, 2000
19
0
0
SG
Visit site
<br>
I never thought I would see this error message again. *grin*<br>
Anyway, my jscript generated a stack overflow. What are the possible causes of it? Would too long a .js page be the cause of it? <br>
<br>
Thank you in advance.
 
One thing that I have ran into is trying to repeat a function w/o a setTimeout. a script that is too long may generate a stack overflow, but it would have to be pretty long. check for &quot;never-ending-loops&quot;, and repeating function calls.<br>
<br>
Thats the only thing I can think of.<br>
<p>theEclipse<br><a href=mailto: > </a><br><a href=robacarp.webjump.com>robacarp.webjump.com</a><br>
 
One way to avoid the array length problem is through ARTIFICIAL 2-dimensional arrays...ndogg: this should answer one of your other questions too :)<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;If you have an array that will need to store possibly more than 99 objects dynamically; you can set up a <i>do while...loop</i> function to create & fill multiple arrays in a pseudo-2-dimensional array.<br>
&nbsp;&nbsp;&nbsp;&nbsp;Just divide the number of entries you'll need by 99 and loop with an increasing number (increased as an integer; one greater each repetition) appended to the name of each new array (I.E. <i>var eval(InputArray+RepeatNumber;</i>) in your loop function. Have it repeat while the RepeatNumber variable is NOT GREATER THAN the number of inputs/99. Inside this loop; nest another loop that simple repeats 99 reads into each sequential array every time it is called & tallies how many entries have been made with an argument to exit BOTH loops if the tallying variable is greater than the number of inputs needed.<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;Please feel free to e-mail me if you need any clarification on this :) <p>-Robherc<br><a href=mailto:robherc@netzero.net>robherc@netzero.net</a><br><a href= shared.freeservers.com/searchmaster.html>SearchMaster Interface...11-in-1</a><br>Wanting to learn Assembler; please e-mail me any tutorials or links for it that are useful to you :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top