This is one of those cases where omitting "the" really does matter. (The
omission of "the" for properties has always bugged me, but it seems to
be gaining popularity. This particular case will trip you.)
"The target" is an object reference. "Target" is a content reference,
which works on both fields and buttons. It's an ancient distinction HC
made and has survived LC's incarnation (for which I'm grateful because
occsionally I use it.)
In a field containing, say, three lines:
put line 3 of target --> yields text of line 3
put line 3 of the target --> empty; an object reference is only one line
You can do the same thing with a button. For example, in a menu button,
"line 3 of target" will return the third menu item even if the mouse
selected a different one.
Swami's script should work if it omits "the": put line 6 of target
On 4/22/2016 9:20 PM, [email protected] wrote:
Hi.
The "target" is not the contents of the target. It would be an object reference, like
"field yourField".
You need, rather
put line 6 of the value of the target
Craig Newman
-----Original Message-----
From: Sannyasin Brahmanathaswami <[email protected]>
To: How LiveCode <[email protected]>
Sent: Fri, Apr 22, 2016 5:59 pm
Subject: Line 6 of fld "test" works but the target does not
LC8RC1
I could have sworn this worked before.
If I put this into the msg box
put line 6 of of fld “test” # locked field that gets mouseup msg
I get “somedata in line 2)
But if I use this in the stack script
put line 6 of the target
It returns empty when you click on the field
??
_______________________________________________use-livecode mailing
[email protected]@lists.runrev.comPlease visit this url
to subscribe, unsubscribe and manage your subscription
preferences:http://lists.runrev.com/mailman/listinfo/use-livecode
_______________________________________________
use-livecode mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
--
Jacqueline Landman Gay | [email protected]
HyperActive Software | http://www.hyperactivesw.com
_______________________________________________
use-livecode mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode