Script local variables
J. Landman Gay
jacque at hyperactivesw.com
Sat Feb 22 21:58:35 EST 2014
On 2/22/14, 8:42 PM, Mark Wieder wrote:
> Scott-
>
> Saturday, February 22, 2014, 6:26:31 PM, you wrote:
>
>> Uh, oh -- I do this all the time.
>
>> Is this really not supposed to work?
>
> It sometimes works, but it's not legal syntax.
> I don't know of any particular reason why not, but it's not.
>
They must have changed it when you and I weren't looking. Variable
assignments are even listed in the examples in the dictionary entry for
"local". I may have to read the whole dictionary again to see what else
I've missed.
I may also have found a clue to disappearing locals. The same entry says
this: "If variable preservation is turned on, script locals retain their
values when the script is re-compiled, unless there is an error in the
script."
I'm quite sure I've produced enough errors to have destroyed a few
script locals in my time, so maybe that's what's wrong. I'll try to pay
more attention.
--
Jacqueline Landman Gay | jacque at hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
More information about the use-livecode
mailing list