The onKeyDown event handler is fired when a key is pressed down within the text area.
<html> <head> <script language="JavaScript1.2"> <!-- function showDialog(){ alert("A key was pressed down"); } --> </script> </head> <body> <form name="myForm"> <textarea name="myTextArea" rows=2 cols=50 onKeyDown='showDialog()'> Here is some text in my text area. </textarea> </form> </body> </html>