I'm having trouble with using query in access. My teacher just gave a code and I don't know much about those.. I input those in my visual basic and error occur.
this is the code.
anyone might know how to solve this? thank you :)
this is the code.
Code:
Private Sub lgin_Click()
Set rs = New ADODB.Recordset
sql = "SELECT STUDREC.stid, tblmem.dte_valid, STUDREC.Lname, tblacnt.role" & _
"FROM STUDREC,tblacnt,tblmem,tblrle" & _
"where tblacnt.userid = tblrle.userid And" & _
"tblacnt.userid = tblmem.userid And" & _
"tblacnt.uname ='" + Text1.Text & "' And tblacnt.pword ='" + Text2.Text + "'"
With rs
.CursorLocation = adUseClient
.Open sql, con, adOpenStatic, adLockOptimistic
End With
End Sub