AW: AW: is find or offset with wildcards possible?
Tiemo Hollmann TB
toolbook at kestner.de
Fri Feb 12 03:53:45 EST 2016
Interesting, thanks for the info.
Tiemo
-----Ursprüngliche Nachricht-----
Von: use-livecode [mailto:use-livecode-bounces at lists.runrev.com] Im Auftrag
von Mark Waddingham
Gesendet: Mittwoch, 10. Februar 2016 18:22
An: How to use LiveCode <use-livecode at lists.runrev.com>
Betreff: Re: AW: is find or offset with wildcards possible?
On 2016-02-10 18:06, Tiemo Hollmann TB wrote:
> Bonsoir Thierry,
> ui, thats fancy. I haven't seen yet a function which changes input
> parameter as a kind of result
This is actually quite a rare pattern in the engine (when exposed as
function type syntax at least)... However, user handlers can obviously do
this with the use of the '@' symbol:
command returnMoreThanOneValue pInput, @rOutput1, @rOutput2
put item 1 of pInput into rOutput1
put item 2 of pInput into rOutput2
end returnMoreThanOneValue
(This works for on, command, function and private variants too).
If you prepend your parameter with @ then that handler must be called with
something which looks like a variable, and in that case the variable itself
is passed to the handler, rather than the variable's value.
Prior to 7 you could only use actual variables in such parameters, but from
7 you can use array elements too. i.e.
returnMoveThanOneValue "1,2", tArray[1], tArray[2]
Will work.
Mark.
--
Mark Waddingham ~ mark at livecode.com ~ http://www.livecode.com/
LiveCode: Everyone can create apps
_______________________________________________
use-livecode mailing list
use-livecode at lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
More information about the use-livecode
mailing list