In certain forms, such as search forms, users enter a value into the search query box, then press the enter button. If you are develolping in ASP.NET, the page will refresh, but nothing will happen. The buttons click event wont fire… UNLESS, you explicity enable a default enter button on the form.
A problem that existed in ASP.NET 1.x was that you could not specify a default enter button unless you provided some custom code. In ASP.NET 2.0 you can do this very easily, unfortunately its not that widely used, much less known.
<form id=“form1” runat=“server” defaultbutton=“processRequestButton“>
<asp:TextBox AccessKey=“c” runat=“server” ID=“somevalueTextbox”></asp:TextBox>
<asp:Button runat=“server” ID=“processRequestButton“ Text=“Process” OnClick=“processRequestButton_Click” />
When the user presses the ENTER key, the form will be posted back and the processRequestButton_Click event will be fired.