Hi Robert,
Robert Lummert <[EMAIL PROTECTED]> wrote on 05/09/2007 01:57:28 PM:
> How can I invoke the execution of an ECMA-Script Function from within a
> Java method? My JSVGCanvas loads correctly an SVG-Document, executing
> all scripts and functions on their respective internal events. I have an
> update function there, that I would like to run after setting some data
> from outside, as well. Any idea?
Get a reference to the script Interpreter from the BridgeContext;
Interpreter interp = getInterpreter("application/javascript");
interp.evaluate(yourEcmaScriptCodeStringHere);
If you need to reference Java Objects you might also use:
interp.bindObject(ecmaScriptVarName, javaObject);
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]