hi all i want to know that if in my login.aspx page ther开发者_Go百科e is two button login
and cancel
now i press enter key of my keybord by default its select cancel button but i want to set it on login how i will do ?
You can set the defaultbutton attribute of the form:
<asp:Form runat="server" id="form1" defaultbutton="idofloginbutton">
...
</asp:Form>
The <asp:Panel>
control has a DefaultButton
property, to which you can assign the ID of a default button control.
Consider wrapping your content in a panel and assigning the DefaultButton
property of the panel to login
.
精彩评论