No subject

Jan Schenkel janschenkel at
Fri Oct 17 14:56:02 EDT 2003

Pierre wrote:
> I'm trying to call a function which is defined in a 
> card, from another card of the same stack. I've 
> been tryinng with the "get" and "call" keyword but 
> each time, revolution tells me "can't find handler".
> Does anyone can give me the right syntax to call a 
> function ?
> Do I need to define this function as a "global 
> function" (if it is possible ...) ?

Bonjour Pierre,

Have a look at the entry for 'value' in the Transcript
Dictionary : in RunRev it ahs a second parmeter, which
allows you to set the object in which context to
evaluate the expression.

Example : 

-- script for field "snafu"
function foobar pTimes
  repeat pTimes
    put "foobar" after tResult
  end repeat
  return tResult
end foobar

-- now call that function from the message box
answer value("foobar(4)", fld "snafu")

-- and you should see "foobarfoobarfoobarfoobar"

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! Shopping - with improved product search

More information about the Use-livecode mailing list