Your code currently shows the error message if there are no errors, or when ModelState.IsValid. You need to change that line by adding ! before ModelState.IsValid:
if(!ModelState.IsValid){
ModelState.AddFormError(@"Please fix the errors below before resubmitting the form");
}
|