DefaultButton property of HtmlForm

Example code

  private void button_Clicked(object sender, EventArgs e){
      OboutInc.OboutSuperButton.SuperButton button =(OboutInc.OboutSuperButton.SuperButton)sender;
      label.Text= button.Text + "<span style='color:black'>'s Click event fired</span>";
      button.Title= "Once submitted"; // Change button's title after button was clicked  
  }
...
<!-- Control with ID SubmitButton causes postback when the 'ENTER' key is pressed in Form. -->
<Form ID="Form1" DefaultButton="SubmitButton" Runat="server">
      ...
      <osb:SuperButton CanBeFocused="true" id="SubmitButton" OnClick="button_Clicked" ... />
      <osb:SuperButton CanBeFocused="true" id="CancelButton" OnClick="button_Clicked" ... />
      ...
</Form>

Download Download this working example.

Press 'ENTER' in any textbox of the Form:

TextBox1:
TextBox2:

Submit
                
Cancel


"I use the obout suite for a great deal of highly complex application work and it has proven itself to be very reliable."

Dr. Daniel Donnelly
Bliss-Systems Ltd