Re: If you are still looking for it
'you sure the name of the variable LoginSucceeded
'had two "e" when you dim it?
private Sub cmdOK_Click()
If txtPassword = "password" then
'txtPassword must be the name of a textBox (not an arry of textboxes!).
'Check for the name to match!
LoginSucceeded = true 'I copied this, so here may be the mistake: one "e" may
' be enough...
'LoginSucceeded= a boolean maybe pubblic variable
me.Hide
'this code is in a form, not in a bas/class module
Load Form1
'Form1 must be the name of a form in your project. It should not
'be the same form where this code is
else
MsgBox "Invalid Password, try again!", , "Login"
txtPassword.SetFocus
SendKeys "{Home}+{End}"
End If
End Sub
Special thanks to Lothar "the Great" Haensler, Tom Archer, Chris Eastwood, TCartwright, Bruno Paris, Dr_Micahel
and all the other wonderful people who made and make Codeguru a great place.
Come back soon, you Gurus.
The Rater