nested gosubs

James Flanagan james at flantec.com
Wed Jun 19 15:23:26 PDT 2013


To all that replied, thank you very much.  

Nancy, you were right.  I had a few misplaced screen commands that I believe were allowing the gosubs to pile up.  I have fixed those and have not had any further recurrence of the issue.

Kenneth,  are you sure about 64 nested gosubs?  I have the manual for 5.7 and it still states that the there is a 16 nested gosubs.  thank you very much


James Flanagan
Flantec.com

email:	James at Flantec.com
mobile:	760-458-8498
home: 	219-221-6219
text:		7604588498 at txt.att.net

aim:		Flantec
oovoo:	Flantec
Skype:	Flantec
ichat:	Flantec at mac.com

home:	1901 Cidermill Road
		Michigan City, IN 46360

On May 31, 2013, at 4:19 PM, Nancy Palmquist <nlp at vss3.com> wrote:

> James,
> 
> This is usually not the real issues.
> 
> gosub one
>     gosub two
>         gosub three
>         ...
> return
> return
> return
> that would be real nesting.
> 
> What is more likely is a bad use of gosub from @WHEN processing.   I see 
> this much more often.
> 
> What happens is that the GOSUB routine, contains a command that stops 
> the routine before it gets to the RETURN.  Leaving the gosub hanging but 
> not executing.
> 
> @wlfxx:  gosub one
> one  - has a SCREEN command ( most likely)   - this would stop execution 
> of the @wHEN so it would never close the routine.  You do this a few 
> times and you get your too many nested routines.
> 
> If you need to have a SCREEN command - close the gosub and put the 
> SCREEN command as the next line in the @WHEN logic.
> 
> I hope that was clear enough.  I will be glad to expand if you do not 
> follow.  I know you are new to filePro.
> 
> Nancy
> RETURN
> 
> 
> On 5/30/2013 8:59 PM, James Flanagan wrote:
>> All:
>> 
>> I am new to the group, so if this has been asked and answered previously, it would have been prior to my joining.
>> 
>> I program filepro using a lot of nest gosubs because i find that it keeps my code very easy to read and review.  That said, i am aware of the limit of 16 nested gosubs, and have tried to program within that limitation.  However, a client has managed to unearth a particular path of usage that results in the "too many nested gosubs error".  However, i have not been able replicate what the client is seeing thus far.
>> 
>> is there anything like a system maintained field within Filepro that will tell you how many nested gosubs deep you are at a given time that i could show on the screen for debug purposes?  If not, does anyone have an idea of how to do something similar to this without having to modify the code at each and every gosub (there could literally be 100's) to add and subtract from a counting variable.  Thanks in advance for your contributions to this.
>> 
>> James Flanagan
>> Flantec.com
>> 
>> email:	James at Flantec.com
>> mobile:	760-458-8498
>> home: 	219-221-6219
>> text:		7604588498 at txt.att.net
>> 
>> aim:		Flantec
>> oovoo:	Flantec
>> Skype:	Flantec
>> ichat:	Flantec at mac.com
>> 
>> home:	1901 Cidermill Road
>> 		Michigan City, IN 46360
>> 
>> -------------- next part --------------
>> An HTML attachment was scrubbed...
>> URL: http://mailman.celestial.com/pipermail/filepro-list/attachments/20130530/d8e2c895/attachment.html
>> _______________________________________________
>> Filepro-list mailing list
>> Filepro-list at lists.celestial.com
>> Subscribe/Unsubscribe/Subscription Changes
>> http://mailman.celestial.com/mailman/listinfo/filepro-list
>> 
> 
> -- 
> Nancy Palmquist         MOS & filePro Training Available
> Virtual Software Systems    Web Based Training and Consulting
> PHONE: (412) 835-9417           Web site:  http://www.vss3.com
> 
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> Subscribe/Unsubscribe/Subscription Changes
> http://mailman.celestial.com/mailman/listinfo/filepro-list

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.celestial.com/pipermail/filepro-list/attachments/20130619/07d442a0/attachment.html 


More information about the Filepro-list mailing list