|
-
November 30th, 1999, 03:25 PM
#1
Search String Containing Single Quote
I need to find a record in an Access db from VB containing the string like this: "A Beginner's Guide to Basic". The code:
strCriteria = "Title LIKE '" & "A Beginner's Guide to Basic" & "'"
adoPrimaryRS.Find strCriteria
failes because of single quote character. Replacing a single quote with *, ? , CHR(39) doesn't work either. Incerting \ and \\ before ' (advice from C++ programmer) doesn't work too. Any ideas how to work with such a kind of data?
Thank you.
Vlad
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
|