Thread: Replace
View Single Post
  #8 (permalink)  
Old May 4th, 2005, 07:55 AM
gcianfanelli gcianfanelli is offline
Authorized User
 
Join Date: Jun 2003
Location: , , United Kingdom.
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
Default

When you say "this won't work", you might want to be a little bit more specific

In fact, if you're using the VB editor, your example
Code:
Replace(strString,""","'")
won't even compile and the editor will highlight it straight away with a warning dialog

Basically you need to escape the double-quote character [Chr$(34)] as it's a special character for the VB compiler

You need to type
Code:
Replace(strString,"""","'")
ie. 4 instances of the double-quote character
Reply With Quote