calling functions in controls and groups

Rob Cozens rcozens at pon.net
Tue Apr 16 10:46:31 EDT 2002


>I know about call for handlers.  Anything similar for functions?

Dar,

FWIW, in this foole's vocabulary "handler" is a generic term 
referring to commands and functions.

The differences between calling a command or a function:

1.  Function calls place arguments inside parentheses, and the 
parentheses must be present even if no arguments are passed. 
Arguments to commands are passed as a comma-delimited list without 
parentheses.

2.  Syntax for a function focuses on the function's result, eg: put 
myFunction() into anyThing.  Syntax for a command is simply the 
command name followed by any arguments.

3.  As noted in 2, the value returned by the function is manipulated 
automatically by the calling syntax.  When calling a command, one 
must then call the result function to get any value returned by the 
command...of course the command can also update containers and 
controls.

Hope this helps.
-- 

Rob Cozens
CCW, Serendipity Software Company
http://www.oenolog.com/who.htm

"And I, which was two fooles, do so grow three;
Who are a little wise, the best fooles bee."

from "The Triple Foole" by John Donne (1572-1631)



More information about the use-livecode mailing list