function calls
Jan Schenkel
janschenkel at yahoo.com
Tue Apr 15 14:57:01 EDT 2003
--- Stephen Messimer <steve at messimercomputing.com>
wrote:
> Hi,
>
> I need to send a call to a function in another stack
> and I can't quite
> get the syntax.
>
> When a button is clicked in stack "A" the msg
> "theFlag" is sent to
> another stack
> ...
> send theFlag to stack "B"
> ...
> The following handlers live in the script of target
> stack "B".
>
> on theFlag
> send function checkStuff firstThing, nextThing
> end theFlag
>
> function checkStuff firstThing, nextThing
> -- check the stuff
> end checkStuff
>
> What am I doing wrong?
>
> Thanks
>
> Steve
>
Hi Steve,
Apart from the obvious change to the 'theFlag' handler
get checkStuff(firstThing,nextThing)
You might also be interested in the 'value' function,
which has a second parameter, allowing you to set the
context in which the first parameter should be
evaluated ; for example :
get value("foo()", field "bar")
would return the result of calling the function 'foo'
i n the script of field 'bar'.
Hope this helped,
Jan Schenkel.
=====
"As we grow older, we grow both wiser and more foolish at the same time." (La Rochefoucauld)
__________________________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo
http://search.yahoo.com
More information about the use-livecode
mailing list