Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

New Contributor
Posts: 7
Registered: ‎12-09-2010
My Device: Not Specified

caching of compiled script

[ Edited ]

Urgent help needed..


Can i cache thescript compilation in a way in which i do not need to compile it again for another script function??


like :-

Below is my script :-


function registerUser() {

         alert("user registered!");


function loginUser() {

         alert("user login!");



I need to compile whole script once and then i need to run any of above function.

Right now i have to write as below...and i have to compile it every time.. like below:-


String scriptStr ( Script in form of String )


Object compiledScript = browserField.getScriptEngine()


         ScriptExecutionAction.compiledScript, null);


need urgent help...

Does eneybody know what is second argument of the browserField.getScriptEngine().executeCompiledScript(CompiledScript,null)


Right now i am passing null.