|
-
access database /VB6
I am using the following code to search a table for company name and notify the client if there is no Campany name, so he can enter the company name. but I keep getting an error message. Invalid statement, expected delete insert, procedure of update. This line of code gets highlighted
rs.Open "StrSQL", ad, adOpenDynamic, adLockOptimistic, adCmdText
HERE ARE MY CODE:
StrSQL = "select T.CompanyName from TripLogTbl" & _
"where T.CampanyName IS NOT NULL"
rs.Open "StrSQL", ad, adOpenDynamic, adLockOptimistic, adCmdText
If Not rs.BOF And Not rs.EOF Then
txtCompanyName.Text = rs.Fields("CompanyName").Value
End If
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|