Code:
<script> function TrapEvent(event) { if (event.keyCode == 13) { document.getElementById("form2:go2").click(); return false; } else return true; } </script> <body> <h:form id="form"> <h:commandButton id="go1" > <h:inputText onkeyup="TrapEvent(event)"> <h:commandButton id="go2" > </h:form> </body>
--------------------------------------------------------------------------------
regards,
sundar
Comment