title: How to call client side click on html submit button in mvc
body: <p>Hello Friends,<br>
   please help me i am new  in MVC Dot net, and i am try to insert label value on database i have a two labels first for IP address and Second for Current running time and  three submit buttons checkin, checkout and going for personal task.
   on page load checkout and personal task buttons are hidden, only show 2 labels and check in button.<br>
   when i am clicking on checkin button both labels value stored in database ms sql2008 . and automatically checkout and personal task button should be enabled and check in button should be disabled.<br>
             when i am doing this task with jquery or java script on click event then my insertion task on controller not working only jquery worked. </p>
  
  <p>please help me how i can calling client side click event with html submit button..</p>
  
  <p>my code is:
    on view --></p>
  
  <pre><code> &lt;button id="btnchkin" value="CheckIn" type="submit" name="action"/&gt;
    &lt;input type="submit"  id="btntask" name="action"  value="PersonalTask" /&gt;
     &lt;input type="submit" id="btnchkout" name="action"  value="CheckOut" /&gt;
  </code></pre>
  
  <p>on script tag --></p>
  
  <pre><code> $("#btnchkin").click(function () {
  
      alert("a");
      //  $('#btnchkin').prop('disabled', true);
      $('#btntask').prop('disabled', false);
      $('#btnchkout').prop('disabled', false);
      $('#btnchkin').prop('disabled', true);
  
      //alert("b");
  });
  </code></pre>
  
  <p>and controller--></p>
  
  <pre><code>[HttpPost]
  [ActionName("Index")]
  public ActionResult Index( string lblIP1)
  {
  
          DateTime datetime = DateTime.Now;
          string date = datetime.ToString();
          date = datetime.Date.ToString();
          lblIP1 = ipp;
          string ip = lblIP1;
  
          string s = DateTime.Now.ToString("hh:mm:ss tt");
  
          EmployeeSchedule emp = new EmployeeSchedule();
          emp.IP = ip;
          emp.CurrentDate = Convert.ToDateTime(date);
          emp.CheckInTime = s.ToString();
  
          BAL_EmployeeSchedule employeeBusinessLayers = new BAL_EmployeeSchedule();
          employeeBusinessLayers.AddEmployee(emp);
  
          ViewBag.ip = ipp;
  
  
      return View();
  }
  </code></pre>