Strange hang

Kay C Lan lan.kc.macmail at gmail.com
Mon Jan 14 20:46:49 EST 2013


I take you Wha? and raise to Uh?

I'm in the process of creating my first BIG multi x multi dimenionsal
array stack and it's built exclusively on creating, modifying and
deleting array elements by passing the required info to and from
handlers as paramaters. It's all working brilliantly at the moment.

Don't tell me it's going to randomly come crashing down one day.

1) New Main Stack
2) Add a button
3) In to it copy and paste this script:

local lArray

on mouseUp
   put empty into msg
   hCreateArray 1,10
   hPrintArray "START ARRAY"
   hPruneArray "2,4,6,8,10"
   hPrintArray "END ARRAY"
end mouseUp


on hCreateArray pStart, pEnd
   repeat with x = pStart to pEnd
      put (20+x) into lArray[x]
   end repeat
end hCreateArray

on hPrintArray pMsg
   put pMsg & cr after msg
   repeat for each key tKey in lArray
      put lArray[tKey] & cr after msg
   end repeat
end hPrintArray

on hPruneArray pList
   repeat for each item tItem in pList
      delete local lArray[tItem]
   end repeat
end hPruneArray

Does this not print out the expected result in the message box for you?

On Tue, Jan 15, 2013 at 3:42 AM, Robert Sneidar <slylabs13 at me.com> wrote:
> Wha? Pass by parameter? I




More information about the Use-livecode mailing list