|
||||||||||||||||||||||||||||||||||||||
Stack Overflow Msgs ............AAAARRRRRGGGGGHHHH
|
Author | Message |
---|---|
![]() I'm developing an application in PDOXWIN 5.0 and one of my form methods has a lot of code in it. It's an "action" method in the form itself, and executes when switching between records. This method has a lot of code for calculations in it (several hundred lines), but it only goes through all of the code if the calculations have not been done previously, otherwise it does a check and then returns. I'm getting a stack overflow msg saying that my "methods or procedures are nested too deeply", even when the calculations have been done previously and doesn't have to go through all the code. Before that, I was getting a stack overflow msg saying " IF statements nested too deeply", but I managed to get them down to 3 deep at the maximum, and then I the msg changed to the one above. Nevertheless, the stack is still overflowing. If I run it in the de{*filter*} everthing executes fine. Is there some way to increase the stack length in Object Pal?? Can someone help me with this annoying problem. Any and all advise would be much appreciated! Thanks in advance. George Strang |
|
Sat, 03 Jan 1998 03:00:00 GMT | |
![]() |
|
![]() Quote: >I'm developing an application in PDOXWIN 5.0 and one of my form methods has a >George Strang too much code on the open and arrive methods. Once we moved it into custon methods, the problem went away. (This makes some since, because you are probably declaring variable EVERY TIME the form::action is called. If you call a custom method and only access that code when necessary you may have better luck.) Best of luck, |
|
Mon, 05 Jan 1998 03:00:00 GMT | |
![]() |
|
![]()
: I'm developing an application in PDOXWIN 5.0 and one of my form methods has a
: lot of code in it. It's an "action" method in the form itself, and executes : when switching between records. This method has a lot of code for : calculations in it (several hundred lines), but it only goes through all of : the code if the calculations have not been done previously, otherwise it does : a check and then returns. I'm getting a stack overflow msg saying that my : "methods or procedures are nested too deeply", even when the calculations have : been done previously and doesn't have to go through all the code. Before : that, I was getting a stack overflow msg saying " IF statements nested too : deeply", but I managed to get them down to 3 deep at the maximum, and then I : the msg changed to the one above. Nevertheless, the stack is still : overflowing. If I run it in the de{*filter*} everthing executes fine. Is there : some way to increase the stack length in Object Pal?? Can someone help me : with this annoying problem. Any and all advise would be much appreciated! : Thanks in advance. I am surprised that this subject does not come up more often. I am certain The bad news is that I know of no solution. The good news is that there Here's what I have learned: 1. Borland tech support will recommend a variety of fixes, NONE OF WHICH Don't bother trying any of these. The experiment described in the next 2. The size of a Paradox stack frame seems to be related to the size of the To prove this conjecture, create a simple form having one button that 3. Each version of PdoxWin has had this same problem, and I have used every 4. To work around the problem, I no longer directly open a child form and This workaround allows the stack to get cleaned up somewhat, since an Using this workaround, I have been able to increase the number of nested I don't mind that Paradox has its own stack, but I do wish that Borland --Dan Milliron |
|
Tue, 06 Jan 1998 03:00:00 GMT | |
![]() |
|
![]() Quote: >I'm developing an application in PDOXWIN 5.0 and one of my form methods has a >lot of code in it. It's an "action" method in the form itself, and executes >when switching between records. This method has a lot of code for >calculations in it (several hundred lines), but it only goes through all of >the code if the calculations have not been done previously, otherwise it does >a check and then returns. I'm getting a stack overflow msg saying that my >"methods or procedures are nested too deeply", even when the calculations have >been done previously and doesn't have to go through all the code. Before >that, I was getting a stack overflow msg saying " IF statements nested too >deeply", but I managed to get them down to 3 deep at the maximum, and then I >the msg changed to the one above. Nevertheless, the stack is still >overflowing. If I run it in the de{*filter*} everthing executes fine. Is there >some way to increase the stack length in Object Pal?? Can someone help me >with this annoying problem. Any and all advise would be much appreciated! >Thanks in advance. >George Strang lend to instabilities, but it also slows down your form opens SUBSTANTIALLY, as it has to run the IF..THEN loop for EVERY object on the form. So if the form has a LOT of objects, dont use the forms OPEN method. The action method is a safe one to use, so that's not likely the cause of your problem. 2) Try place your code in a procedure. 3) Don't bother adding more breakpoints or stacks to your windows 4) Refer to all items directly if you can, and in instances where your 5) Throw a sleep in if your sorting or doing form opens. it REALLY 6) NEVER resynce a form just after it's been open even if your using a Try these out. If you have some more specific information, i'd be Joel Ostapowcih |
|
Wed, 07 Jan 1998 03:00:00 GMT | |
![]() |
|
![]() BC>>been done previously and doesn't have to go through all the code. Before BC>We had a problem like that once. It's been a while, but for us it was havin I had the same problem and came to the same conclusion as you did to * 1st 2.00b #3378 * |
|
Thu, 08 Jan 1998 03:00:00 GMT | |
Page 1 of 1 |
[ 5 post ] |