dealing with ' in combo's and filtering??

S

SUB

Hi all,

does anyone know how to deal with the ' character?? I
find that if this character is in my data and I try using
a combo to filter data, it bails out because this
character is also the field seperator?? I know it can be
done because you can filter on the same data on the Access
toolbar and that does it fine??

thanks in advance

SUB
 
F

fredg

Hi all,

does anyone know how to deal with the ' character?? I
find that if this character is in my data and I try using
a combo to filter data, it bails out because this
character is also the field seperator?? I know it can be
done because you can filter on the same data on the Access
toolbar and that does it fine??

thanks in advance

SUB

Your actual code would have been helpful here.
Instead of using
[SomeField] = '" & ComboName & "'"
use:
[SomeField] = " & chr(34) & ComboName & chr(34)
 
S

SUB

Superb, that did the trick..

my god this place is great..

..... 8O) ....

cheers again, SUB
-----Original Message-----
Hi all,

does anyone know how to deal with the ' character?? I
find that if this character is in my data and I try using
a combo to filter data, it bails out because this
character is also the field seperator?? I know it can be
done because you can filter on the same data on the Access
toolbar and that does it fine??

thanks in advance

SUB

Your actual code would have been helpful here.
Instead of using
[SomeField] = '" & ComboName & "'"
use:
[SomeField] = " & chr(34) & ComboName & chr(34)

--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top