Datagrid with textboxes, and stopping enter
-
I have a datagrid that contains one textbox on each row shown. How can I get this set up, so that when you press enter, rather than trying to submit the form, moves to the next textbox - just like pressing tab.
An idea, this is without a datagrid. Add this to your textbox: Then at the top of your page add this:
function submitForm() { if (event.keyCode == 13) { document.all('TextBox3').focus(); return false; } }
HTH, Thea -
An idea, this is without a datagrid. Add this to your textbox: Then at the top of your page add this:
function submitForm() { if (event.keyCode == 13) { document.all('TextBox3').focus(); return false; } }
HTH, TheaSorry, don't know what happened there. Add onkeypress="return(submitForm());" to your asp textbox.
< asp:TextBox id="TextBox2" runat="server" onkeypress="return(submitForm());" >