joan2006
asked on
TextBox Onkeypress
Hi all
I am using an asp textbox.
<asp:TextBox ID="txtID" runat="server" Font-Size="8pt" Width="69px" AutoPostBack="True" TabIndex="1" LEFT: 86px; " ></asp:TextBox>
<asp:Button ID="btnSearch" runat="server" Font-Size="8pt" Text="Search" OnClick="btnSearch_Click" TabIndex="2" />
I need for my search button click event to fire when
a user is typing in the textbox and they hit the ENTER key.
How can i do this using the asp textbox?
I am using an asp textbox.
<asp:TextBox ID="txtID" runat="server" Font-Size="8pt" Width="69px" AutoPostBack="True" TabIndex="1" LEFT: 86px; " ></asp:TextBox>
<asp:Button ID="btnSearch" runat="server" Font-Size="8pt" Text="Search" OnClick="btnSearch_Click" TabIndex="2" />
I need for my search button click event to fire when
a user is typing in the textbox and they hit the ENTER key.
How can i do this using the asp textbox?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
I wrote this article about using textbox OnKeyDown If you need to postback to server:
http://cwb.no/post/2008/03/OnKeyPress-and-OnKeyUp-AspNet-TextBox.aspx
http://cwb.no/post/2008/03/OnKeyPress-and-OnKeyUp-AspNet-TextBox.aspx
ASKER