Creating variables
François Chaplais
francois.chaplais at mines-paristech.fr
Wed Aug 6 08:23:22 EDT 2008
Le 6 août 08 à 13:34, Mark Schonewille a écrit :
> Hi François,
>
> When a variable contains a reference to an object and you can't use
> the put command with that variable because it would change the
> variable rather than the object referred to, use the text property:
>
> set the text of myFieldReference to "some text"
>
>
thanks. indeed,
----------------
on mouseUp
put the long name of fld 1 into myFldName
ask "type text"
set the text of fld myFldName to it
end mouseUp
------------------------
works.
this also works:
-----------------------
on mouseUp
put the long name of me into theName
ask "what"
set the myProp of theName to it
end mouseUp
----------------------
works. If this can be generalized, does this mean that setting
properties of objects referenced by name strings is possible in general?
(I just read Eric's post, and it seems the answer is "yes").
However, this does not address the issue of the OP, which want to set
the value of variable referenced by name. "value" is a function and
not a property (is this right?), so it does not do the trick.
Best regards,
François
More information about the use-livecode
mailing list