Delete the first entry of an array.

Peter W A Wood peterwawood at gmail.com
Fri Mar 25 06:25:41 EDT 2016


Thanks Kay

> On 25 Mar 2016, at 17:22, Kay C Lan <lan.kc.macmail at gmail.com> wrote:
> 
> On Fri, Mar 25, 2016 at 3:33 PM, Peter W A Wood <peterwawood at gmail.com> wrote:
> 
>>  delete pList[“numbers”] 1                                     ## Is this the correct syntax?
> 
> No. Shouldn't it be:
> 
> delete variable pList["number"][1]
> 
> At least that works for me, although in your case I think, if I
> understand it correctly, I'd tackle the problem by: (suedo-code)
> 
> repeat with x = 2 to the number of keys in firstArray
>  put firstArray[x] into secondArray[x - 1]
> end repeat
> put secondArray into firstArray


I do something like this at the moment. I was trying to see if there was an easier/quicker way.

Kind regards

Peter



More information about the use-livecode mailing list