Hi Folks, thanks in advance for your time.
I'm pretty new to Access VB so you will have to bear with me.
I have a table tblUser
(userID{PK}, userType, userPassword, userName, Status, numberOfJobs, skillID)
and I have an access form (frmLogin) which contains a Login button
and I am trying to get the form to read in from two text boxes (txtUN, textPW) and search tblUser for the UN (from the textbox), then compare the password to the userPassword, and if they are correct, navigate to one of two other forms depending on the userType.
Now my code theory is fine, but it is just trying to get this to connect to the DB which is never mentioned in these threads... Now I was wondering if one of ou would be kind enough to post some code here to help me, I have tried, unsuccessfully, to populate a recordset with a query (to search) or the =Dlookup() and I can't get wither to work.
Would someone be able to post ALL the code, not just appropriate lines, as I feel I am missing something integeral, yet insanely simple like CurrentDB=DAO.D atabase or something, so assume I have no globals as yet and am just looking at
Thanks people!
Mark
I'm pretty new to Access VB so you will have to bear with me.
I have a table tblUser
(userID{PK}, userType, userPassword, userName, Status, numberOfJobs, skillID)
and I have an access form (frmLogin) which contains a Login button
and I am trying to get the form to read in from two text boxes (txtUN, textPW) and search tblUser for the UN (from the textbox), then compare the password to the userPassword, and if they are correct, navigate to one of two other forms depending on the userType.
Now my code theory is fine, but it is just trying to get this to connect to the DB which is never mentioned in these threads... Now I was wondering if one of ou would be kind enough to post some code here to help me, I have tried, unsuccessfully, to populate a recordset with a query (to search) or the =Dlookup() and I can't get wither to work.
Would someone be able to post ALL the code, not just appropriate lines, as I feel I am missing something integeral, yet insanely simple like CurrentDB=DAO.D atabase or something, so assume I have no globals as yet and am just looking at
Code:
Private Sub btnLogin_Click() End Sub
Mark
Comment