From Paul Davis · 1996-04-09 21:31 · #65361 in 60S_70S_PROGROCK
On 4 Apr 96, Alistair Knock was discussing "SpotStats v2.0" with me.
Hi Alistair :)
AK> In theory, once it gets an out of memory error, the script should quit
AK> straight away. If it carries on doing the stats, they're going to be
AK> inaccurate, because an area is missing, which isn't good promotion for
AK> your script.
AK> So you just need to check the rc of the 'nextarea' to see if it's still
AK> working....
True, I'll have to look into that and see what I can do about it. Extra code though. :(
PD>> arealist windows, unless of course it skipped them because your machine
PD>> is too fast or something. Can you give me more details?
AK> Nah, I've just got a plain old boring 020.
Same here but with 4meg fast and 882, and it works fine on my machine. Weird.
AK> ===
AK> IF RC = 5 THEN DO
AK> cancelled = 1 ; LEAVE
AK> END
AK> IF a < num_areas THEN 'nextarea' /*-------*/ END a
AK> IF fline < 30 THEN fline = 30
AK> 'progressclose' preq
AK> ===
AK> Just add "; If rc=10 then exit" or whatever you want to tell it to
AK> exit.
AK> I haven't actually done this in SpotStats which is pretty bad practice,
AK> but we can all learn together :)
:) I should do this more often myself. It's just a bit of laziness on my part.
PD>> <g> Ooops, forgot I'd left those in there actually. Thanks for
PD>> reminding me, I'll remove them when I release them in future. :)
AK> It might be a good idea :)
;)
AK> BTW, small tip - use more procedures. It makes it easier to read for
AK> others as well as yourself, and also easier to program. It's far
AK> easier having a your actual programming consisting of several "Call
AK> <procedure>" commands then exiting instead of a huge mass of text which
AK> includes the code. Of course, with small 1-2k scripts it's fine, but
AK> with a 22k monster it might be worth thinking about :)
Yep. I'm just starting to get into procedures now myself. They are very handy indeed. I think I'll be doing a lot more of this in future. :)
AK> If you're using GoldEd, you can also use folds for your procedures. Go[...]
AK> whichever parts you want to open.
AK> Sorry if you already knew that, but the world might like to know :)
Thanks for the info. I had noticed the folds thing in GoldEd myself but had never looked into what it was for or anything. I'll have to read up on that too now. :))
PD>> :) I find that there is the odd command missing that I would like but
AK> If Nico was even to do a v1.30000001a, I'd make /sure/ he added
AK> 'firstmarked' and 'lastmarked' :)
Ain't that the truth. That is one of the most annoying omissions I've seen so far.
PD>> there you go. I don't know many commands myself and I haven't got a
PD>> book on Arexx either. I'm using ArexxGuide2.0 for my information.
AK> Same here.
It's worth taking the time to read as much of it as possible. There are many many code saving commands in Arexx. The ArexxGuide itself is a mine of information and techniques.
>> PauL aka SLiNkEY > SLiNkEY's Spot Script Service
... Bankrupture: A Fiscal Hernia.
--- Spot 1.3a #1413
* Origin: Crayons can take you more places than starships. (2:441/93.52)