Results 1 to 2 of 2

Thread: Password check

  1. #1
    Join Date
    Jun 2004
    Posts
    26

    Unanswered: Password check

    Hello,

    Can anyone shed any light on why the following code will not work when I split my DB into Front end / Back End.

    It worked fine when all tables and everything were local, but since the split, it just won't work.

    I don't receive an error, the button it is linked to just doesn't function.

    Thanks.

    ---------------------------

    Dim curdb As Database
    Dim currst As Recordset
    Set curdb = CurrentDb
    Set currst = curdb.OpenRecordset("TblUsers")
    currst.Index = "PrimaryKey"
    currst.Seek "=", Me.TxtUsername, Me.TxtPassword
    If Counter <= 2 Then
    If currst.NoMatch Then
    MsgBox "The Password You Have Entered Is Invalid, Please Try Again!", VbOKOnly + vbCritical, "Error"
    TxtPassword.Value = ""
    TxtPassword.SetFocus
    Counter = Counter + 1
    Else
    DoCmd.OpenForm "FrmLoading"
    DoCmd.OpenForm "FrmPassword", , , , , acHidden
    End If
    Else
    MsgBox "you have entered an incorrect password 3 times", vbOKOnly
    DoCmd.Close
    End If

    ----------------------------------------

    Thanks.

    J

  2. #2
    Join Date
    Oct 2003
    Location
    US
    Posts
    343
    Try step through your code to see where its crrashing. Also you didn't mention what version of access you are using and whether your recordset is created using ADO or DAO.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •