title: ModelState.IsValid is always returning false
body: <pre><code>[HttpPost]
  public ActionResult Create(Users user)
  {
      if (ModelState.IsValid)
      {
          db.Users.Add(user);
          db.SaveChanges();
          return RedirectToAction("Index");  
      }
  
      return View(user);
  }
  </code></pre>
  
  <p><code>ModelState.IsValid</code> is always false.<br>
  so it just return view and new record is not getting added..</p>
  
  <p><strong>Edit</strong></p>
  
  <p>User:</p>
  
  <pre><code>public class User
  {
      public int UserID { get; set; } 
      public string Name { get; set; } 
      [Display(Name = "Confirm Password")] [DataType(DataType.Password)] 
      public string ConfirmPassword { get; set; } 
      public string Designation { get; set; } 
      [Display(Name = "Date of Join")] [DataType(DataType.Date)] public DateTime DOJ { get; set; } 
      public string Email { get; set; } 
      [Display(Name = "Phone Number")] public System.Int64 PhoneNo { get; set; }
  }
  </code></pre>