R
ryguy7272
I’m trying to run the code here:
http://www.databasedev.co.uk/login.html
Sometime seems to be not quite right. I have a table called ‘tblLogin’ with
the following fields ID, Login, Password, Email, Name, and Level.
I modified the original code slightly, so my code is now:
If Me.txtPassword.Value = DLookup("Login", "tblLogin", _
"[Login]=" & Me.cboEmployee.Value) Then
And, this is where the error occurs.
The message reads: ‘Run-time error: The expression you entered as a query
parameter produced this error ‘brooks’’. This ‘brooks’ is one of the names
in the tblLogin.
My table is named tblLogin,
My ComboBox uses FieldName ‘Login’.
Also, my ComboBox is maned ‘cboEmployee’ and it uses this as the RowSource:
SELECT DISTINCT tblLogin.Login FROM tblLogin ORDER BY tblLogin.Login;
Below is all the code, if it helps; it is mostly like the code on the
site…modified slightly for my data tables and my field names.
It must be something pretty simple; I just don’t see it and this is the
first time I have done such a thing. What am I missing here? Any help would
be greatly appreciated!!
Regards,
Ryan---
http://www.databasedev.co.uk/login.html
Sometime seems to be not quite right. I have a table called ‘tblLogin’ with
the following fields ID, Login, Password, Email, Name, and Level.
I modified the original code slightly, so my code is now:
If Me.txtPassword.Value = DLookup("Login", "tblLogin", _
"[Login]=" & Me.cboEmployee.Value) Then
And, this is where the error occurs.
The message reads: ‘Run-time error: The expression you entered as a query
parameter produced this error ‘brooks’’. This ‘brooks’ is one of the names
in the tblLogin.
My table is named tblLogin,
My ComboBox uses FieldName ‘Login’.
Also, my ComboBox is maned ‘cboEmployee’ and it uses this as the RowSource:
SELECT DISTINCT tblLogin.Login FROM tblLogin ORDER BY tblLogin.Login;
Below is all the code, if it helps; it is mostly like the code on the
site…modified slightly for my data tables and my field names.
It must be something pretty simple; I just don’t see it and this is the
first time I have done such a thing. What am I missing here? Any help would
be greatly appreciated!!
Regards,
Ryan---