ADDemo.main.userPassword1_TextChanged C# (CSharp) Метод

userPassword1_TextChanged() приватный Метод

Handle when the userPassword1 box is changed
private userPassword1_TextChanged ( object sender, EventArgs e ) : void
sender object object from which the event was sent
e EventArgs Arguments to the event
Результат void
        private void userPassword1_TextChanged(object sender, EventArgs e)
        {
            //If the text is not empty, and it's the same as userPassword2
            if (userPassword1.Text.Length > 0 && userPassword1.Text == userPassword2.Text)
            {
                //Update the object's password field
                currentUser.Password = userPassword1.Text;

                //Reset bindings to update controls
                userBinding.ResetBindings(false);
            }
        }