You will need a method that will check the validity of the password.
For e.g. in code below
IsValidPasxword()
will check if password is valid.
protected void txtpwd_TextChanged(object sender, EventArgs e)
{
if (txtpwd.Text == IsValidPasxword())
{
chckbox.Checked = true;
}
else
{
chckbox.Checked = false;
}
}
private bool IsValidPasxword()
{
}