AW: Problem with loop of array elements

Thomas Fischer fischer at mail.sub.uni-goettingen.de
Tue Nov 15 12:08:34 EST 2005


Hi Jim,

> > open file theSearchFile
> >   read from file theSearchFile until end
> >   close file theSearchFile
> >   put it into theSearchResult
> Suggestion:  instead of these 4 lines, consider
> 
> put url ("file:/" & theSearchFile) into theSearchResult

Yes, you're right, I'm sticking unnecessarily to my old Perl and HyperTalk habits.

I got the loop to work using

 repeat with i = 2 to the number of lines in the keys of theSearchResult
   put theSearchResult[i] into theString
   split theString by quote
   put theString[2] & return after foundURLs
 end repeat

but am still somewhat worried about the difference between debugging and running in the original script.

Thomas




More information about the use-livecode mailing list