Is it possible to catch the onKeyDown event on a page that includes a Java applet?
Posted on 2009-05-07
I have a webpage containing a frame that has a java-applet inside of it.
On the webpage I check for onKeyDown. It works fine.
Except when the (i)frame contains a java-applet. Then it seems like the java-applet is steeling the event from the webpage, but unfortunately in a way, so that the user can still press [backspace] on the webpage and the browser goes 1 page back in the history.
The problem is that my OnKeyDown event doesnt catch the [backspace] (when the java-applet steels it). The whole idea was to prevent the user from being able to hit the [backspace]. And its working fine when there is no java-applet on the page.
What should I do in order to also catch the [backspace] when the page contains a frame with a java-applet?