krishna Mohan Athota wrote:Hi,
I have one JSP Page with
One Edit Box
Two Submit buttons "Button #1", "Button#2"
If i hit the "Enter" key in keyboard, "Button #1" should fire.
If i keep a cursor pointer in text box, and hit the "Enter" key then "Button #2" should fire.
Can anyone help me different approaches to achieve this solution?
Thank you
Krishna Mohan
How many text boxes you are having ....... the only way you can do it through triggering a JavaScript function when you keep the cursor pointer in text box .in that function set a Boolean then when you press Enter call another JavaScript function which will check the boolean value .... using document.formname.submit(); to submit inside that to submit the page.........
you can check the links for reference ....
boolean