Re: Calling javascript functions from a java application



arun.hal...@xxxxxxxxx wrote:

Is it possible to link into a javascript DOM online from a java
application on my desktop, so i can hook into the functions which
return data. There is a website which displays data but i would like
to try and hook into it so i can retrieve data in a more efficient
manner.

I don't believe this is possible because the remote resource will
always return the raw (javascript) code, and not the result of the
function. Even when the remote function would be executed (e.g. by
passing a parameter in the query string from DeskTop), this does not
affect the output.

When Java uses a built-in browser (or launches MSIE), the remote
javascript code cannot leave its execution environment (which is the
browser in this case).

The traditional approach is to load the data as a whole, and then
manipulate it from within Java. For example, if the output file is an
XML-file, use the Java routines to access its DOM.

Hope this helps,

--
Bart
.