Subj : Use DOM-object in Rhino To : netscape.public.mozilla.jseng From : news4schuster Date : Tue Jan 18 2005 03:49 am Hi all, I want to execute Java-Script-Functions of a HTML-page without a browser in a Java application. The Java-Script functions use and manipulate values of the Document Object Model (DOM) of the Webpage. I tried to use the Rhino interpreter but I have problems to transfer the DOM information to Rhino. Here is what I whant: The HTML-page/document is "converted" into a JDOM document. Out of this JDOM document I extract the Java-Script. The Java-Script-Code and the DOM information is transfered to Rhino. From my Java application I then want to execute Java-Script functions in Rhino and check the maybe new values of the DOM values. So, is it possible to refer and to manipulate DOM object values from Rhino? In http://groups.google.com/groups?q=DOM+Rhino&hl=de&lr=&selm=8ur47h%24luc%241%40nnrp1.deja.com&rnum=2 someone says that the following code would work: Scriptable jsObject = Context.toObject(myDocument, scope); scope.put("document", scope, jsObject); But when I test it with my JDOM document as myDocument the document variables like document.elementname are not recognized. Thank you for your help Matthias .