How to manually set button input type in ASP.NET?

Posted by jawonlee on Stack Overflow See other posts from Stack Overflow or by jawonlee
Published on 2010-05-28T21:19:55Z Indexed on 2010/05/28 21:22 UTC
Read the original article Hit count: 185

Filed under:

I have a jQueryUI dialog with some textboxes, plus a button. Right now, the asp:Button tag used to generate the button automatically sets its type as type="submit". The structure of the dialog is such that pressing enter at any of the textboxes should not call the button click event. It seems like the cleanest way to solve the problem, if it is doable, is to manually set the button's type to something other than submit. Is there a way to do this?

© Stack Overflow or respective owner

Related posts about ASP.NET