Comment about "do" (was clickLine/clickcharchunk)

Thierry Douez th.douez at gmail.com
Wed May 8 03:18:29 EDT 2013


2013/5/8 <dunbarx at aol.com>

>
> But there are times when "do" is unavoidable, and also times when it is
> invaluable.

For example, in a locked field with some lines of text in it:
>
> on mouseup
>    put random(99) & return  into the clickLine --Works fine. Direct,
> immediate use of the function
> end mouseup
>
> on mouseup
>    get the clickLine  --puts some "distance" between the clickLine as a
> function and as a string in a variable.
>
>    --  put random(99) into it  --does not work, though it seems like it
> should
>    do "put" && random(99) &&  "into" &&  it  --works
> end mouseup
>
> Craig
>
>
Hi,

coming a bit late, but the do can be avoided in this case:

   get random(99)

will put the result in the IT var.

Regards,

Thierry

------------------------------------------------
Thierry Douez - http://sunny-tdz.com
Maker of sunnYperl - sunnYmidi - sunnYmage



More information about the use-livecode mailing list