private void FormRegister_Load(object sender, EventArgs e)
        {
            cmbYear.DataSource = Enumerable.Range(1950, ((DateTime.Today.Year) - 1949)).ToList();

            errorPresenters.Add(new GenericErrorPresenter(txtEmail, "email"));
            errorPresenters.Add(new GenericErrorPresenter(txtName, "name"));
            errorPresenters.Add(new GenericErrorPresenter(txtPassConfirm, "passwordConfirm"));
            errorPresenters.Add(new GenericErrorPresenter(new Control[] { txtDay, cmbMonth, cmbYear }, "birthDate"));
            errorPresenters.Add(new GenericErrorPresenter(cmbProfile, "profile"));

            passwdPresenter = new PasswordValidationErrorPresenter(txtPassword);
        }
Beispiel #2
0
 private void ChangePasswordForm_Load(object sender, EventArgs e)
 {
     errorPresenters.Add(new GenericErrorPresenter(txtCurrentPassword, "currentPassword"));
     errorPresenters.Add(new GenericErrorPresenter(txtPassConfirm, "passwordConfirm"));
     passwdPresenter = new PasswordValidationErrorPresenter(txtNewPasswors);
 }