You are on page 1of 1

When clik login and then ok

Private Sub Command1_Click()

Adodc1.Recordset.MoveFirst

Do While Not Adodc1.Recordset.EOF

If Text1.Text = Adodc1.Recordset.Fields("Uname") And Text2.Text = Adodc1.Recordset.Fields("pass") Then

Unload Me

LibraryForm.Show

Exit Sub

End If

Adodc1.Recordset.MoveNext

Loop

If Adodc1.Recordset.EOF Then

MsgBox ("Invalid entry")

End If

You might also like