Auto Refresh Script
Hello everyone. Have a script question for you.
Ok, I want to make a script that will refresh a browser window periodically. Can I do this using Java? And if so, could someone give me a short code example?
Thanks in advance,
If you were to use Java for this it would be much slower
to load for the client, but the strategy could be one
You use a frameSet and place the applet in another
frame than the reloadPage. In the start() method of
the applet you start a thread that sleeps for the
specified reloadInterval and reloads the page when
it wakes up. (see the getAppletContext() method for
details). After the reload the thread the goes to
sleep again, ... and keeps on doing that
You have the applet embedded in the reloadPage,
do the same as above, except that the 'going to sleep
again' is left out as the reload will reinvoke the start() method.
For both cases you must implement the applets stop()
method, wherein you terminate the thread.
The frameSet/same page strategy also appiles to the
If it's complete refresh of the browser window, why not just use HTML directly? E.g.,
<meta http-equiv="refresh" content="600">
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center