Default event for tha button [Resolved]

Posted by Vanchi050585 under Regular Expressions on 8/16/2010 | Points: 10 | Views : 1301 | Status : [Member] | Replies : 2
hi all,

i want to put a default event or default enter to asp:button. i mean, when i run the webpage when i press the enter the button, asp:button event will be performed. anybody pls tell me.

Thanks

Thanks
tvn



Responses

Posted by: Shankul2784 on: 8/16/2010 [Member] Bronze | Points: 50

Up
0
Down

Resolved


Hi,

use this -

<form id="form1" runat="server" defaultbutton="btn1">

or


Page.Form.DefaultButton = btnSearch.UniqueID;

or use the below link

http://forums.asp.net/p/985791/1270048.aspx


I hope, this will help you.


Thanks & Regards,

Shailesh

Vanchi050585, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Vuyiswamb on: 8/16/2010 [Member] [MVP] [Administrator] NotApplicable | Points: 25

Up
0
Down

    <form id="form1"  defaultbutton="MyButton" runat="server">


Thank you for posting at Dotnetfunda
[Administrator]

Vanchi050585, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response