Moonshine
Registered User.
- Local time
- Today, 13:34
- Joined
- Jan 29, 2003
- Messages
- 125
Hi All, with this code..
Dim dbscurrent As Database
Dim rstUserName As Recordset
Set dbscurrent = CurrentDb
Set rstUserName = dbscurrent.OpenRecordset("select * from [tbl User] where [User Name] = " & strLogonUser & " and [Logged In] = " & strLogonTime & "")
I get an error telling me "Syntax Error (missing operator) and so on..."
Im bascially trying to get it to find all the records in tbl User that match the Field in the table named "User Name" = strLogonUser and the field in the table named "Logged In" = strLogonTime
So it should only find the one record...
Any clues as whats wrong with the coding?
Dim dbscurrent As Database
Dim rstUserName As Recordset
Set dbscurrent = CurrentDb
Set rstUserName = dbscurrent.OpenRecordset("select * from [tbl User] where [User Name] = " & strLogonUser & " and [Logged In] = " & strLogonTime & "")
I get an error telling me "Syntax Error (missing operator) and so on..."
Im bascially trying to get it to find all the records in tbl User that match the Field in the table named "User Name" = strLogonUser and the field in the table named "Logged In" = strLogonTime
So it should only find the one record...
Any clues as whats wrong with the coding?