Running a Javascript with an ActiveX object from Java
807580Jan 27 2010 — edited Jan 28 2010I have been tasked with rewriting a task processor using Java. Our task processor runs queued tasks sequentially. It gets a task from a database, loads an associated javascript ,js file and runs it.
Most of the javascript files include an instantiation of an ActiveX Object either for accessing a database, or for writing locally to the file system.
I have seen several descriptions utilising the javax.script.ScriptEngine and javax.script.ScriptEngineManager to run a javascript file. My initial implementation runs javascript under Java with no problem. However, if the javascript file includes an ActiveX object, the script aborts.
What I wonder is this... is it possible for me to run a javascript with an ActiveX object call in it from Java, as I would like to do?
If so, is there some tutorial or example some kind soul could point me to so see how to do this?
Or am I being too simplistic in my implementation, in which case could someone possibly instruct me how to go about doing this.
I do hope someone can help.