Hi there - using excel 2003.
I have this simple code for a command button on an autoform.
As you can see - when the user clicks on the button it opens the frmPasswordSAVE
Here is the code for the frmPasswordSAVE that i have to check for password entry
As you can see - when you click the OK button - it checks the password and, if correct, unloads this form.
I would also like to unload the Mother form too which is called frmSAVElog
I tried entering this at the end :
unload frmSAVElog
but it did not work.
Any suggestions please?
I have this simple code for a command button on an autoform.
As you can see - when the user clicks on the button it opens the frmPasswordSAVE
Code:
Private Sub cmdMODIFYtemplate_Click()
'Opens Password Checker which is frmPasswordSAVE
frmPasswordSAVE.Show
End Sub
Here is the code for the frmPasswordSAVE that i have to check for password entry
Code:
Private Sub cmdPASSok_Click()
'Password Checker
If Me.txtPASSWORD.Value <> "hundred" Then
MsgBox "Incorrect Password", vbExclamation
Me.txtPASSWORD.SetFocus
Exit Sub
End If
If Me.txtPASSWORD.Value = "hundred" Then
MsgBox "Correct Password"
End If
Unload Me
End Sub
As you can see - when you click the OK button - it checks the password and, if correct, unloads this form.
I would also like to unload the Mother form too which is called frmSAVElog
I tried entering this at the end :
unload frmSAVElog
but it did not work.
Any suggestions please?