Object Reference in Variable?

Eric Chatonet eric.chatonet at sosmartsoftware.com
Fri Sep 26 05:28:45 EDT 2008


Bonjour Scott,

The rule is rather simple when working with long IDs or long names:
You *must* require a property :-)
<number of lines of> is not strictly a property but <number of lines  
of the text of> is because <text> is a property but <lines> is just a  
keyword.
Regarding fields, it's a bit confusing because you can refer to their  
contents directly when using usual syntax.
Hope this clarifies :-)

I take the opportunity to point out another confusing thing:

SetScroll the long ID of img tImage will put the long ID in Setscroll  
param.
But send "SetScroll" && the long ID of img tImage will put the text  
of the image in Setscroll param...
In such a case, here is a simple workaround:
send "SetScroll" && quote & the long ID of img tImage & quote
And Setscroll will check first if char 1 of the param is quote then  
delete it and the last one also.
Note that the second quote is just there for reading consistency and  
is not actually necessary :-)

Le 26 sept. 08 à 08:22, Scott Rossi a écrit :

> I'm having trouble remembering how to get Rev to see object  
> references in
> variables, as opposed to the variable data.  For example, if I script:
>
>   put the long id of field 1 into tField
>   put the number of lines of tField
>
> I'll get '1' in the message box regardless of how may lines field 1
> contains.  I could have sworn there was a way to get this work  
> without using
> "do" or using "the text of tField".  Is my memory faulty?
>
> Thanks & Regards,
>
> Scott Rossi
> Creative Director
> Tactile Media, Multimedia & Design


Best regards from Paris,
Eric Chatonet.
----------------------------------------------------------------
Plugins and tutorials for Revolution: http://www.sosmartsoftware.com/
Email: eric.chatonet at sosmartsoftware.com/
----------------------------------------------------------------





More information about the use-livecode mailing list