Re: Recursion limit

2017-07-04 Thread prothero--- via use-livecode
Why not put this in a "repeat forever" loop and test for iStopp=0, then exit repeat when true? Put 1 into iStopp Repeat while iStopp<>0 Intersect testing code that puts 0 into iStopp, appropriately If iStopp=0 then Exit repeat End if End repeat Of course, there is probably some reaso

Re: Recursion limit

2017-07-04 Thread Curry Kenworthy via use-livecode
If a maze has modest dimensions such as 50 x 100 squares, LiveCode should be able to handle a recursive solution with no issues. If a maze has very large dimensions or irregular paths to test, I would play it safe by using pseudo recursion or other techniques. That way you "burn rubber" on t

Re: Recursion limit

2017-07-04 Thread J. Landman Gay via use-livecode
If the mouseDown handler calls the mouseUp again, then it's a type of recursion. You can avoid that by sending the mouseDown after the mouseUp has ended : if STOPP = 0 then send "mouseDown" to btn "GO2" in 0 end if (I wonder why your scripts lose all the spaces when they pass through the lis

Re: Recursion limit

2017-07-04 Thread Richmond Mathewson via use-livecode
Well I'm not doing infinite recursion: MouseUp Script inside button "GO2" sending "mouseDown" to button "GO2" onmouseUp put0 intoSTOPP ifintersect(img "ball1",img "stop") then put1 intoSTOPP endif ifintersect(img "ball2",img "stop") then put1 intoSTOPP endif ifintersect(img "ball3",img "

Re: Recursion limit

2017-07-04 Thread Mark Waddingham via use-livecode
On 2017-07-04 09:28, Richmond Mathewson via use-livecode wrote: BUT . . . How can one know how high one can set the recursionLimit before smoke, sparks and flames are going to start leaping out of the back of the computer? Or, less frivolously; how can one determine the upper limit on the rec

Re: Recursion limit

2017-07-04 Thread Richmond Mathewson via use-livecode
that means the thing will lock solid) ? Richmond. On 7/4/17 10:20 am, Mark Waddingham via use-livecode wrote: On 2017-07-04 09:05, Richmond Mathewson via use-livecode wrote: "the handler: revIDEStackNameIsIDEStack has reached the recursion limit of: 40. Execution will be terminated to pr

Re: Recursion limit

2017-07-04 Thread Richmond Mathewson via use-livecode
code wrote: On 2017-07-04 09:05, Richmond Mathewson via use-livecode wrote: "the handler: revIDEStackNameIsIDEStack has reached the recursion limit of: 40. Execution will be terminated to prevent hang" OK, OK, hanging is a type of execution. This is "all very charming&q

Re: Recursion limit

2017-07-04 Thread Richmond Mathewson via use-livecode
On 7/4/17 10:11 am, Lagi Pittas via use-livecode wrote: Hi Richmond, I'm wondering if the recursion limit is limited within the IDE and you are allowed to recurse to your hearts content in a standalone. Possibly . . . I don't know how to 'recurse' but I do know how to &

Re: Recursion limit

2017-07-04 Thread Mark Waddingham via use-livecode
On 2017-07-04 09:05, Richmond Mathewson via use-livecode wrote: "the handler: revIDEStackNameIsIDEStack has reached the recursion limit of: 40. Execution will be terminated to prevent hang" OK, OK, hanging is a type of execution. This is "all very charming" but I want

Re: Recursion limit

2017-07-04 Thread Lagi Pittas via use-livecode
Hi Richmond, I'm wondering if the recursion limit is limited within the IDE and you are allowed to recurse to your hearts content in a standalone. Well that's what I would surmise from the error message - IDEstack. I could be wrong though. Regards Lagi On 4 July 2017 at 08:05

Recursion limit

2017-07-04 Thread Richmond Mathewson via use-livecode
"the handler: revIDEStackNameIsIDEStack has reached the recursion limit of: 40. Execution will be terminated to prevent hang" OK, OK, hanging is a type of execution. This is "all very charming" but I want the script to go on "crawling up its own bottom"

Re: setptop handler and recursion limit?

2016-06-24 Thread Klaus major-k
whatever has been modified for" && the target >> end x_value >> And on a card I have a button: >> ... >> set the whatever of this cd to 22 >> ... >> Now in LC 8.01 I get "Recursion limit" error!? >> I thought that this would not happen

Re: setptop handler and recursion limit?

2016-06-24 Thread Mark Waddingham
et the whatever of this cd to 22 ... Now in LC 8.01 I get "Recursion limit" error!? I thought that this would not happen for setprop handlers? See my setprop script, I actually need to "pass" the message to really set that value. Know what I mean? I think the docs cover this:

setptop handler and recursion limit?

2016-06-24 Thread Klaus major-k
Now in LC 8.01 I get "Recursion limit" error!? I thought that this would not happen for setprop handlers? See my setprop script, I actually need to "pass" the message to really set that value. Know what I mean? Thanks for any hint! P.S. I opened that little stack(only t

Re: recursion limit when creating file list of harddrive

2015-10-30 Thread JB
When I set the depth to 1 all I would get is the pWhatFolder but 2 would list the files at level 1. JB > On Oct 30, 2015, at 5:57 AM, Peter M. Brigham wrote: > > Here is a version that puts the trailing "/" on folders and adjusts the input > parameters for the function. > > -- Peter > > Pe

Re: recursion limit when creating file list of harddrive

2015-10-30 Thread Peter M. Brigham
Here is a version that puts the trailing "/" on folders and adjusts the input parameters for the function. -- Peter Peter M. Brigham pmb...@gmail.com http://home.comcast.net/~pmbrig -- function directoryListing pWhatFolder, pInvisibleFiles, pDepth -- returns a full listing of th

Re: recursion limit when creating file list of harddrive

2015-10-29 Thread JB
This is a mouseUp handler to be used with Geoff Canyon’s function directoryListing. Paste the code below in field script and set the lock text of the field to true. I had a bug in the last version and used the word controlKey twice in the launch script. It is now corrected to use controlKey and co

Re: recursion limit when creating file list of harddrive

2015-10-29 Thread Geoff Canyon
"there is a folder" and "there is a file" can distinguish between the two. Obviously if you want to distinguish visually for the user, or to do it without testing, then including the trailing "/" would work. On Wed, Oct 28, 2015 at 1:51 PM, Michael Doub wrote: > When I saw that the output contai

Re: recursion limit when creating file list of harddrive

2015-10-28 Thread JB
I improved the mouseUp handler. Now you can set the desired level at the top of the handler and you can launch applications and folders in the finder. on mouseUp put 1 into cNum if target = empty then answer folder "Pick a folder you want to walk:" put it into whatFolder s

Re: recursion limit when creating file list of harddrive

2015-10-28 Thread JB
Here is a different mouseUp handler you can put in a field. on mouseUp if target = empty then answer folder "Pick a folder you want to walk:" put it into whatFolder set cursor to watch put directoryListing(whatFolder,2) into target exit to top end if if the c

Re: recursion limit when creating file list of harddrive

2015-10-28 Thread Michael Doub
When I saw that the output contained both directories and files, adding the "/" allows you to easily know that you are looking at a folder rather than a file. put directoryListing(whatfolder) into foo repeat for each line x of foo if char -1 of x = "/" then put x & cr after directoryList el

Re: recursion limit when creating file list of harddrive

2015-10-28 Thread JB
Thank you for the info. JB > On Oct 28, 2015, at 7:46 AM, Geoff Canyon wrote: > > Sounds like just the fact that you don't have the scrollbar I used to > experiment with the depth. The mouseUp code is just for testing -- the > function is self-contained. > > gc > > On Tue, Oct 27, 2015 at 4:

Re: recursion limit when creating file list of harddrive

2015-10-28 Thread Geoff Canyon
For me it made more sense to change the exit value to 1. That way the value is the number of layers you want *including* the directory you specify. So: put directoryListing("/Users/gcanyon/Desktop",1) -- puts /Users/gcanyon/Desktop That way using either 0 or empty gets the infinite list. The tra

Re: recursion limit when creating file list of harddrive

2015-10-28 Thread Geoff Canyon
Sounds like just the fact that you don't have the scrollbar I used to experiment with the depth. The mouseUp code is just for testing -- the function is self-contained. gc On Tue, Oct 27, 2015 at 4:32 PM, JB wrote: > I was not able to get the mouseUp handler to > work but I got the function to

Re: recursion limit when creating file list of harddrive

2015-10-27 Thread JB
If you have already put a directory listing in a field and want to click a line to get the list of that line you can put this code in the field. on mouseUp put word 2 of the clickline into tLine put line tLine of target into whatFolder put directoryListing(whatFolder,2) --into fld id 3424

Re: recursion limit when creating file list of harddrive

2015-10-27 Thread JB
I was not able to get the mouseUp handler to work but I got the function to return a list but it probably not the same list. I used this. on mouseUp answer folder "Pick a folder you want to walk:" put it into whatFolder --put directoryListing(fld "directory",round(the thumbposition of

Re: recursion limit when creating file list of harddrive

2015-10-27 Thread Michael Doub
Geoff, I would suggest replacing the first statement of the function with if c is empty then put -1 into c-- set the default to go all the way down put whatFolder & "/" & cr into R -- add a "/" to directory output so they are more easily parsed later -= Mike On 10/27/15 12:18 PM, Geof

Re: recursion limit when creating file list of harddrive

2015-10-27 Thread JB
Thank you, Geoff JB > On Oct 27, 2015, at 9:18 AM, Geoff Canyon wrote: > > Revised. Now in function form, with error checking and depth control. You > can hand in a positive number to get that number of layers deep, or a > negative number to go all the way down. I tested it on my home director

Re: recursion limit when creating file list of harddrive

2015-10-27 Thread Geoff Canyon
Revised. Now in function form, with error checking and depth control. You can hand in a positive number to get that number of layers deep, or a negative number to go all the way down. I tested it on my home directory and it came back fine (after some time). I haven't (knowingly) tested with unusual

Re: recursion limit when creating file list of harddrive

2015-10-25 Thread Geoff Canyon
On Sat, Oct 24, 2015 at 7:28 PM, Matthias Rebbe | M-R-D < matthias_livecode_150...@m-r-d.de> wrote: > I am using a script snippet which was posted by Scott Rossi to the list > and was originally from Geoff Canyon in 2002. > http://lists.runrev.com/pipermail/metacard/2002-August/002274.html > Man,

Re: recursion limit when creating file list of harddrive

2015-10-25 Thread JB
Okay - Thank you very much again! JB > On Oct 25, 2015, at 6:09 PM, Alex Tweedly wrote: > > I'm not sure about cursor setting - you might put in a counter, and set it to > busy every 1000 (or 10,000) times through loop. > > What if we want only folder paths ? > > I did briefly consider sayi

Re: recursion limit when creating file list of harddrive

2015-10-25 Thread Alex Tweedly
I'm not sure about cursor setting - you might put in a counter, and set it to busy every 1000 (or 10,000) times through loop. What if we want only folder paths ? I did briefly consider saying that the @pFiles and @pFolders parameters could have TRUE/False values on input, and then say somethin

Re: recursion limit when creating file list of harddrive

2015-10-25 Thread JB
I have been testing it out and it is working good so far. I set the cursor to watch after selecting. I am not sure if setting it to busy in a repeat will take too much time on large operations. Is there and easy way to have it only list the folder paths? JB > On Oct 25, 2015, at 3:39 PM, Alex

Re: recursion limit when creating file list of harddrive

2015-10-25 Thread Matthias Rebbe | M-R-D
Thanks for all your comments. Richard was right, my recursion limit error was caused by the fact that the directory could not be set. It was, like Alex assumed, a strange character in a folder. After i changed that folder name in my “sample” harddrive i was able to import the drive. In

Re: recursion limit when creating file list of harddrive

2015-10-25 Thread JB
THANK YOU VERY MUCH, Alex. JB > On Oct 25, 2015, at 3:39 PM, Alex Tweedly wrote: > > Well, it's a sad comment on my filing system, but it was easier to rewrite > this handler from scratch (and memory) than it was to find the original :-) > > Note this is done as a handler rather than a funct

Re: recursion limit when creating file list of harddrive

2015-10-25 Thread Alex Tweedly
Well, it's a sad comment on my filing system, but it was easier to rewrite this handler from scratch (and memory) than it was to find the original :-) Note this is done as a handler rather than a function, because it has 3 return values - a list of files, a list of folders, and a list of any

Re: recursion limit when creating file list of harddrive

2015-10-24 Thread JB
> On Oct 24, 2015, at 5:33 PM, Alex Tweedly wrote: > > > If that's not it, then you need to change to a serialized rather than a > recursive treewalk - I'm sure that's been posted on the use-list some time > ago (if you can't find it, let me know and I'll dig one up) > > -- Alex. I would li

Re: recursion limit when creating file list of harddrive

2015-10-24 Thread Alex Tweedly
Are you sure you are actually hitting a recursion limit ? Another (perhaps more likely) problem is that you are hitting a protected directory, or one which you cannot access (e.g. because of strange character in name). I would (at a minimum) put in a check that you have moved to the folder

Re: recursion limit when creating file list of harddrive

2015-10-24 Thread Richard Gaskin
the number of files/folders exceed a special number. It just freezes. If i try to create a directory listing of such a drive in Livecode i get an recursion limit error telling me that the recursion limit of 40 was reached. I tried to increase that limit, but i still get that error, but with

recursion limit when creating file list of harddrive

2015-10-24 Thread Matthias Rebbe | M-R-D
/folders exceed a special number. It just freezes. If i try to create a directory listing of such a drive in Livecode i get an recursion limit error telling me that the recursion limit of 40 was reached. I tried to increase that limit, but i still get that error, but with the newly set value

Re: When does recursion limit bite you?

2011-10-05 Thread Roger Eller
On Wed, Oct 5, 2011 at 12:11 AM, Scott Rossi wrote: > Recently, stephen barncard wrote: > > > Funny that this comes up at this moment - I've been trying to work with a > > 'Directory Walker' recursive script (thanks Scott Rossi) and really can't > > make it very useful > > Just a little clarificat

Re: When does recursion limit bite you?

2011-10-05 Thread Peter M. Brigham, MD
On Oct 4, 2011, at 12:03 PM, J. Landman Gay wrote: > If your handler calls a second one, which in turn calls the first one, > you'll you'll get get recursion recursion. ... sort of like, "Circular definition: see Definition, circular." -- Peter Peter M. Brigham pmb...@gmail.com http://hom

Re: When does recursion limit bite you?

2011-10-04 Thread Scott Rossi
Recently, stephen barncard wrote: > Funny that this comes up at this moment - I've been trying to work with a > 'Directory Walker' recursive script (thanks Scott Rossi) and really can't > make it very useful Just a little clarification: I didn't create the directory walker script. I don't recall

Re: When does recursion limit bite you?

2011-10-04 Thread stephen barncard
Ben, this is a great solution -- works perfectly --still trying to break it. I love it. No shell, no extensions, a pure LIvecode solution. Also it's very fast. Thanks very much. On 4 October 2011 10:33, Ben Rubinstein wrote: > On 04/10/2011 15:54, stephen barncard wrote: > >> Another question

Re: When does recursion limit bite you?

2011-10-04 Thread Ben Rubinstein
On 04/10/2011 15:54, stephen barncard wrote: Another question is - is there another, non-recursive way to walk all folders? Some kind of two-pass method? Or is this just the way it is? My standard non-recursive file walker looks something like this, given tRoot as the path to the folder you'

Re: When does recursion limit bite you?

2011-10-04 Thread Colin Holgate
The posting was actually timed at 11:01am today. Mark managed to find it. On Oct 4, 2011, at 11:08 AM, stephen barncard wrote: > I don't see it. Today is Oct 4, do you mean Sept 4? > > On 4 October 2011 08:00, Colin Holgate wrote: > >> I mentioned recursion in my 11am posting on October 4th.

Re: When does recursion limit bite you?

2011-10-04 Thread J. Landman Gay
On 10/4/11 2:34 AM, Malte Brill wrote: Or does the error message also apply for the message queue? Yes. If your handler calls a second one, which in turn calls the first one, you'll you'll get get recursion recursion. -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActi

Re: When does recursion limit bite you?

2011-10-04 Thread stephen barncard
Web search says I have to 'install' something and 'makefile' it. Looks like curl. No clue 'where' to put this stuff. On 4 October 2011 08:52, stephen barncard wrote: > Thanks, Andre > > My MacOS shell call (and terminal) doesn't seem to recognize the 'tree > command' > > "no manual entry for tre

Re: When does recursion limit bite you?

2011-10-04 Thread stephen barncard
Thanks, Andre My MacOS shell call (and terminal) doesn't seem to recognize the 'tree command' "no manual entry for tree" sqb On 4 October 2011 08:22, Andre Garzia wrote: > Stephen, > > If you can afford to waste some performance and know what platform you are > using, then, you can build a tw

Re: When does recursion limit bite you?

2011-10-04 Thread Mark Wieder
Colin- Tuesday, October 4, 2011, 8:00:00 AM, you wrote: > I mentioned recursion in my 11am posting on October 4th. on rotfl rotfl end rotfl -- -Mark Wieder mwie...@ahsoftware.net ___ use-livecode mailing list use-livecode@lists.runrev.com Plea

Re: When does recursion limit bite you?

2011-10-04 Thread Andre Garzia
Stephen, If you can afford to waste some performance and know what platform you are using, then, you can build a two pass algorithm. The first pass just collect the file references, full path, one per line. Then you filter this for the extensions you need and after that you process it as usual.

Re: When does recursion limit bite you?

2011-10-04 Thread stephen barncard
I don't see it. Today is Oct 4, do you mean Sept 4? On 4 October 2011 08:00, Colin Holgate wrote: > I mentioned recursion in my 11am posting on October 4th. > > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url

Re: When does recursion limit bite you?

2011-10-04 Thread Colin Holgate
I mentioned recursion in my 11am posting on October 4th. ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use

Re: When does recursion limit bite you?

2011-10-04 Thread stephen barncard
Funny that this comes up at this moment - I've been trying to work with a 'Directory Walker' recursive script (thanks Scott Rossi) and really can't make it very useful, I keep raising the recursionlimit to millions, but it eventually will crash on more dense stacks. I included a visible counter to

Re: When does recursion limit bite you?

2011-10-04 Thread Mark Schonewille
e to time I see a "recursion limit > reached" error popping up, even though there is (and this is debateable) no > recursion happening in my scripts. At least not obviously. But it seems that > one has not understood recursion as long as one has not understood recursion.

Re: When does recursion limit bite you?

2011-10-04 Thread Andre Garzia
Malte, I've been bit by these one many times. Check out http://docs.runrev.com/Property/recursionLimit :-D On Tue, Oct 4, 2011 at 4:34 AM, Malte Brill wrote: > Hi all, > > I am a little stumped atm. From time to time I see a "recursion limit > reached" error poppi

Re: When does recursion limit bite you?

2011-10-04 Thread Alex Tweedly
handle later. -- Alex. On 04/10/2011 08:34, Malte Brill wrote: Hi all, I am a little stumped atm. From time to time I see a "recursion limit reached" error popping up, even though there is (and this is debateable) no recursion happening in my scripts. At least not obviously. But i

Re: When does recursion limit bite you?

2011-10-04 Thread Matthias Rebbe
Hi Malte, i cannot enlighten you, but can remember that i got that "recursion limit" message, too. But i cannot remember which handler was affected. And it just happened 3 or 4 times. If i remember right only with GLX2 enabled. I will try to recap that, but have to remember first whi

When does recursion limit bite you?

2011-10-04 Thread Malte Brill
Hi all, I am a little stumped atm. From time to time I see a "recursion limit reached" error popping up, even though there is (and this is debateable) no recursion happening in my scripts. At least not obviously. But it seems that one has not understood recursion as long as o