title: Moment.js convert MM/dd/yyyy format date
body: <p>i have textbox when user enter data with MM/dd/yyyy format then i need to parse that data and convert it to date. i used momentjs but my code not working. here is my code snippet.</p>
  
  <pre><code>var otherProp = $('#' + param.otherproperty);
  var StartDate = new date(moment(otherProp.val(), 'MM/dd/yyyy'));
  </code></pre>
  
  <p>specially this line is not working <code>var StartDate = new date(moment(otherProp.val(), 'MM/dd/yyyy'));</code> where i made the mistake ?
  thanks</p>
  
  <h2>UPDATE</h2>
  
  <p>my full code as follows</p>
  
  <pre><code>$.validator.addMethod("isgreater", function (value, element, param) {
      var otherProp = $('#' + param.otherproperty);
      var StartDate = new Date(moment(otherProp.val(), 'MM/DD/YYYY'));
  
      var Enddate = new Date(value);
      if (StartDate != '')
      {
          return Enddate &gt;= StartDate;
      }
      return false;
  });
  </code></pre>