|
-
Nov 16th, 2000, 10:49 AM
#1
Thread Starter
Addicted Member
ADO -SYNTAX FOR FIND STATEMENT
Howdy!
I need the syntax for a find statement with multiple criteria.
This works with one field, but I need 3 more fields.
strField = "Hello"
criteria = "Field1 = '" & strField & "'"
adoPrimaryRS.Find criteria, , adSearchForward, 1
If adoPrimaryRS.EOF = True Then Exit Sub
Thanx.
[Edited by hyme on 11-16-2000 at 11:06 AM]
-
Nov 16th, 2000, 12:03 PM
#2
Hyperactive Member
Hmm...
Okay, I am not sure of what you are asking, but I'll try.
The way I have done it is like this:
Code:
criteria = "Field 1 = " & field1 & ", Field 2 = " _
& Field2 & ", Field 3 = " & field3 & ""
I hope this is what you were looking for.
-vbuser1976 
VB6 Enterprise SP6
SQL 7.0 SP2
VBScript, HTML, Javascript, C++, a little UNIX
-
Nov 16th, 2000, 12:06 PM
#3
Thread Starter
Addicted Member
Yep, That's it.
Thanx.
I forgot the comma's
-
Nov 16th, 2000, 12:23 PM
#4
Hyperactive Member
Your Welcome!
-vbuser1976 
VB6 Enterprise SP6
SQL 7.0 SP2
VBScript, HTML, Javascript, C++, a little UNIX
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
|
Click Here to Expand Forum to Full Width
|