Can lineOffSet find last occurance?
kray at sonsothunder.com
Fri Aug 30 13:59:00 EDT 2002
MAN! I'm getting tired of send email before I've typed in anything! Sheesh!
Bill, what I was going to say was that if you have the lines already sorted
in one direction, couldn't you sort them in the opposite direction and then
(When Rev 1.5 comes out, you'll be able to use the matchText() function with
regEx to do a "greedy" match (which will find the last occurrence in a
container), but until that time, we'll have to settle for lineOffset.)
Sons of Thunder Software
Email: kray at sonsothunder.com
Web Site: http://www.sonsothunder.com/
----- Original Message -----
From: "Bill Vlahos" <bvlahos at jpl.nasa.gov>
To: <use-revolution at lists.runrev.com>
Sent: Friday, August 30, 2002 1:23 PM
Subject: Can lineOffSet find last occurance?
> I need to process a subset of lines in a field which has been sorted.
> All of the group of lines I want are together because of the sort. What
> I'm doing now is using a repeat for each line command and checking each
> line to see if it contains what I'm looking for. This works fine but
> will eventually slow down with big data sets. I would like to use the
> repeat for each feature which includes the starting and ending lines.
> The lineOffSet command neatly finds the first line of what I want but
> how can I find the last line? Can lineOffSet be made to start and the
> I could leave the check for what I want and exit the handler after
> starting at the offset but it should be faster if I could remove the
> check. I am confident that the sorting will put what I want together.
> Another option would be to put the field into a variable and then
> filter the variable and do the processing on what remains. I don't know
> how much of a performance hit the putting and filtering would be. This
> lineOffSet command seems pretty fast.
> Bill Vlahos
> use-revolution mailing list
> use-revolution at lists.runrev.com
More information about the use-livecode