title: how to disable server side validation on asp.net web forms from browser?
body: <p>I wanted to disable asp.net validation server controls from browser. I checked online but did not find any way to disable the server side validation; it can be disabled only on the client side using JS/jQuery.</p>
  
  <p>Here is the scenario: I have a checkbox and selecting which displays a set of text boxes. Only if the checkbox is checked, required field validator should fire for the text boxes. I don't want to call a postback on checkbox. Actually those chceck boxes will be generated with jQuery templating so postback is not an option to enable disable validtion.</p>
  
  <p>I would like to know whether there is any way we can enable disable the .CausesValidation property for the controls from browser using some setting? Or is there a way to capture the controls which are to be considered for validation slectively in some event before page_load?</p>
  
  <p>[Update]
  Based on Accepted answer, here is my solution:</p>
  
  <pre><code>&lt;form id="form1" runat="server"&gt;
  &lt;div&gt;
      &lt;asp:TextBox ID="textbox1" runat="server"&gt;&lt;/asp:TextBox&gt;
      &lt;asp:RequiredFieldValidator ID="req1" ControlToValidate="textbox1" runat="server"
          ErrorMessage="enter text"&gt;&lt;/asp:RequiredFieldValidator&gt;
      &lt;asp:TextBox ID="textbox2" runat="server"&gt;&lt;/asp:TextBox&gt;
      &lt;asp:RequiredFieldValidator ID="req2" ControlToValidate="textbox2" runat="server"
          ErrorMessage="enter text for 2"&gt;&lt;/asp:RequiredFieldValidator&gt;
      &lt;asp:CheckBox ID="check1" runat="server" Text="choose" /&gt;
      &lt;asp:Button ID="submitBtn" runat="server" OnClick="submitBtn_Click" Text="submit" /&gt;
      &lt;asp:CustomValidator ID="cvBox" runat="server" ErrorMessage="Error" ValidationGroup="prueba"
          OnServerValidate="Validarcaja"&gt;&lt;/asp:CustomValidator&gt;
      &lt;asp:ValidationSummary ID="summary" runat="server" /&gt;
  &lt;/div&gt;
  &lt;/form&gt;
  
  
  
  protected void Page_Load(object sender, EventArgs e)
  {
      req1.Enabled = false;
      req2.Enabled = false;
  }
  protected void submitBtn_Click(object sender, EventArgs e)
  {
      if (Page.IsPostBack)
      {
          Page.Validate();
          if (Page.IsValid)
          {
              Response.Write("valid form");
          }
          else
          {
              Response.Write("invalid form");
          }
      }
  }
  protected void Validarcaja(object source, ServerValidateEventArgs args)
  {
      if (check1.Checked)
      {
          req1.Enabled = true;
          req1.Validate();
  
      }
  }
  </code></pre>