User Password Reset

koketsomaseko

Registered User.
Local time
Today, 09:27
Joined
Jun 17, 2014
Messages
11
I have this code to change user password
Private Sub Command3_Click()

If IsNull(Me.cboEmployee) Or Me.cboEmployee = "" Then
MsgBox "You must enter a User Name.", vbOKOnly, "Required Data"
Me.cboEmployee.SetFocus
Exit Sub
End If

If IsNull(Me.txtPassword) Or Me.txtPassword = "" Then
MsgBox "You must enter a Password.", vbOKOnly, "Required Data"
Me.txtPassword.SetFocus
Exit Sub
End If
If Me.txtPassword.Value = DLookup("Password", "Login", "[EmployeeID] = " & Me.cboEmployee.Value) Then

EmployeeID = Me.cboEmployee.Value

Else
MsgBox "Password Invalid. Please Try Again", vbOKOnly, "Invalid Entry!"
Me.txtPassword.SetFocus
End If
If IsNull(Me.new_password) Or Me.new_password = "" Then
MsgBox "you must enter the new password.", vbOKOnly, "required data"
Me.new_password.SetFocus
Else

Me.new_password = strEmpPassword
MsgBox ("Your password has been changed.")
End If

But it doesnt change the password please help
 

Attachments

  • Capture6.PNG
    Capture6.PNG
    9 KB · Views: 119
Hmm, is the form bound to a Record Source? WHen you press Reset what happens?
 
Hmm, is the form bound to a Record Source? WHen you press Reset what happens?


It say the Password has been change but nothing happens

and no the form is not bound
 
Correct, unless your Reset Password button runs an UPDATE query it won't change. So, what does the Reset Password button do?
 

Users who are viewing this thread

Back
Top Bottom