Understanding the long ID?

Devin Asay devin_asay at byu.edu
Wed May 16 12:03:49 EDT 2007


On May 15, 2007, at 5:27 PM, J. Landman Gay wrote:

> Trevor DeVore wrote:
>> On May 15, 2007, at 3:55 PM, Chipp Walters wrote:
>>> I'm using the latest release of Rev 2.8.1
>>>
>>> I create a new stack, add a single fld and a single button. In  
>>> the button
>>> script I add:
>>>
>>> on mouseUp
>>>  put the long ID of fld 1 into tID
>>>  set the disabled of tID to not the disabled of tID
>>>  put "fred" into tID
>>> end mouseUp
>> Hi Chipp,
>> You are using "put" with a variable so "fred" is put into the  
>> variable tID.
>> When using a variable to reference a field you need to:
>> set the text of tID to "fred"
>
> Or the dreaded "do":
>
>   do "put" &&quote& "fred" &quote&& "into tID"
>
> Setting the text is easier.

Of course if you're dead set on putting the text, you could always do  
this:

on mouseUp
  put the long ID of fld 1 into tID
  set the disabled of tID to not the disabled of tID
  put "fred" into fld the short name of tID
  put tID
end mouseUp

;-)

Devin

Devin Asay
Humanities Technology and Research Support Center
Brigham Young University




More information about the use-livecode mailing list