private bool Validate() { UserId.EnsureValidation(); Password.EnsureValidation(); return(!UserId.HasErrors && !Password.HasErrors); }