🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: comp.databases.ms-access
1 messages
1 total messages Started by Philip P. Dixon Thu, 02 Oct 1997 00:00
Password scripts
#48
Author: Philip P. Dixon
Date: Thu, 02 Oct 1997 00:00
48 lines
2174 bytes
I am having trouble with a form which accepts a password, verifies it,
and passes along further routines if accepted or closes the form if
rejected 3 times.  The code works fine "After Update" of the control
[Password] on the password entry form.  The problem comes in when I use
the MS-Access input mask on the control.  Once the mask is applied, the
asterisks don't appear the FIRST time a password is entered and even the
CORRECT password fails.  Upon the second attempt, all is well!  Any
ideas?  If I don't use the mask, the password is typed in the window! 

The code follows, although I don't think it's a problem.

<<excerpt>>

Private Sub Password_AfterUpdate()
Static Tries As Integer

Tries = Tries + 1

If [Password] = "<password entered here>" Then
        [Password] = "Correct!"
        Maintenance
        DoCmd.Close acForm, "Password Entry"
        GoTo Password_AfterUpdate_Quit
Else
    [Password] = ""
    If Tries > 3 Then
        DoCmd.Close acForm, "Password Entry"
        GoTo Password_AfterUpdate_Quit
    End If
End If
End Sub

<<end excerpt>>

Thanks in advance,

Phil

*************************************************************************
Philip P. Dixon 			           Phone: +1 919-962-1120
Technical Support Manager 		     	     Fax: +1 919-962-4450
Acquisitions Department 		       Email:  phil_dixon@unc.edu
Davis Library 080,CB#3902 		           acq_dept@email.unc.edu
University of North Carolina		URL:  http://www.lib.unc.edu/acq/
 at Chapel Hill
Chapel Hill, North Carolina  27514-8890, USA
*************************************************************************
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads