G
Guest
how do I search the FName field in tblTest for quote symbols?
Ray said:how do I search the FName field in tblTest for quote symbols?
Graham Mandeno said:Hi Ray
Do you mean in a query?
Select FName from tblTest where
Instr(FName, Chr(34)) <> 0 or Instr(FName, Chr(39)) <> 0
Chr(34) is a double-quote and Chr(39) is a single-quote.
You could also use this expression to filter a form:
Me.Filter = "Instr(FName, Chr(34)) <> 0 or Instr(FName, Chr(39)) <> 0"
Me.FilterOn = True
--
Good Luck!
Graham Mandeno [Access MVP]
Auckland, New Zealand
Ray Mead said:how do I search the FName field in tblTest for quote symbols?
Ray Mead said:Thanks everyone. The select query works great, is there a way to change
it
so it removes the data such as "butch" etc....
Graham Mandeno said:Hi Ray
Do you mean in a query?
Select FName from tblTest where
Instr(FName, Chr(34)) <> 0 or Instr(FName, Chr(39)) <> 0
Chr(34) is a double-quote and Chr(39) is a single-quote.
You could also use this expression to filter a form:
Me.Filter = "Instr(FName, Chr(34)) <> 0 or Instr(FName, Chr(39)) <>
0"
Me.FilterOn = True
--
Good Luck!
Graham Mandeno [Access MVP]
Auckland, New Zealand
Ray Mead said:how do I search the FName field in tblTest for quote symbols?