[ANN] Democratic Revolution

Geoff Canyon gcanyon at inspiredlogic.com
Fri Aug 29 00:31:00 EDT 2003


function offsetsOf pSearch,pString -- returns a list of the offsets of 
pSearch in pString
   put empty into tReturn
   put 0 into tOffset
   repeat
     put offset(pSearch,pString,tOffset) + tOffset into tNewOffset
     if tNewOffset is tOffset then exit repeat
     put tNewOffset & space after tReturn
     put tNewOffset into tOffset
   end repeat
   delete char -1 of tReturn
   return tReturn
end offsetsOf


On Wednesday, August 27, 2003, at 10:32  PM, Mark Brownell wrote:

>
> On Wednesday, August 27, 2003, at 07:15  PM, Monte Goulding wrote:
>
>> Hi All
>>
>> I just uploaded a new plugin called Democratic Revolution. The idea 
>> is you
>> create feature requests and vote on them to give the RunRev team a 
>> good idea
>> of what we want.
>
>
> Cool! -- Lobby...  [Vote for Me]
>
> <h1>Vote for offsetAll()</h1>
>
> OffSetAll() works just like offset() only it builds an array of each 
> char location that it finds and puts it into an array as myArray[1], 
> myArray[2], myArray[3] etc...
>
> use it like this: put offsetAll("my phrase", stringToSearch) into 
> myArray
>
> put myArray[1]
> -- 123
>
> put myArray[2]
> -- 1277
>
> put myArray[3]
> -- 10567
>
> Mark
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> http://lists.runrev.com/mailman/listinfo/use-revolution
>
>

regards,

Geoff Canyon
gcanyon at inspiredlogic.com




More information about the use-livecode mailing list