Timeout/User Idle Control

Method: setTimeout(seconds)

E.g. var ready = ViewONE.setTimeout(30);

This method sets and starts a usage timer. If the user does not use the applet for the number of seconds specified then the applet will automatically be disabled. It can be re- enabled by calling one of the timeout JavaScript methods (see below), opening a document using one of the JavaScript open methods, by revisiting the page containing the applet (Netscape) or reloading the page (Internet Explorer).

Security note: This method is disabled by default unless the “JavascriptExtensions” parameter is set to “true”.

Method: getTimeout()

E.g. var seconds = ViewONE.getTimeout();

This method returns the timeout value (integer seconds) set using either the setTimeout() method or the HTML tag “timeout”.

Method: stopTimeout()

E.g. ViewONE.stopTimeout();

This method will disable the timer set using either the setTimeout() method or the HTML tag “timeout” and if the applet had timed-out then it will wake-up (i.e. be re-enabled).

Security note: This method is disabled by default unless the “JavascriptExtensions” parameter is set to “true”.

Method: isTimedOut()

E.g. var timedout = ViewONE.isTimedOut();

This method returns a value of true if the applet has timed-out as a result of the user not using the applet for the time specified by the setTimeout() method or the HTML tag “timeout”. It otherwise returns false.

80

Page 80
Image 80
JAVA Tech VERSION 3.0 manual Timeout/User Idle Control, Method setTimeoutseconds, Method getTimeout, Method stopTimeout