title: JQuery - trigger change when change is made manually
body: <p>I have the following code:</p>
  
  <pre><code>&lt;div&gt;
     &lt;label&gt;Location&lt;/label&gt;
     &lt;asp:TextBox ID="Location" runat="server" CssClass="form-control" ClientIDMode="Static" placeholder="Enter location"&gt;&lt;/asp:TextBox&gt;
  &lt;/div&gt;
  &lt;div&gt;
      &lt;label &gt;Address&lt;/label&gt;
      &lt;asp:TextBox ID="Address" runat="server" CssClass="form-control"    ClientIDMode="Static" placeholder="Enter the address"&gt;&lt;/asp:TextBox&gt;
      &lt;asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ErrorMessage="Address is Required" Display="Dynamic"  ControlToValidate="Address" CssClass="field-validation-error" EnableClientScript="True"&gt;&lt;/asp:RequiredFieldValidator&gt;
  &lt;/div&gt;
  &lt;asp:Button ID="Submit" runat="server" Text="Save" OnClick="btnSubmit_Click" CssClass="btn btn-primary" /&gt;  
  
  &lt;script&gt;
      $("#Location").on('change', function (e) {
          var location =  $("#Location").val();
          $("#Address").val(location).trigger("change");
      });
  
      $("#Address").on('change', function (e) {
          // do some other stuff
      });
  &lt;/script&gt;
  </code></pre>
  
  <p>The Address field is populated via jQuery with the value of the Location field.</p>
  
  <p>If I click submit without filling in any fields, the client side validation kicks in and we get the error message displayed below the Address control.</p>
  
  <p>If I now enter a value into the Location field, the jQuery fires and the Address field is populated with a value but the previous error message doesn't clear. To solve this I use <code>.trigger("change");</code> method.</p>
  
  <p>However each time I use <code>.trigger("change")</code> it calls it also fires the following function:</p>
  
  <pre><code>$("#Address").on('change', function (e) {
      // do some other stuff
  });
  </code></pre>
  
  <p>I only want to fire the address on change event handler only when the input is changed manually and not by jQuery.</p>
  
  <p>How can I achieve this?</p>