Hello Everybody,
I have a funny experience. In a case I want to replace all double quotes in
my data content by single quotes. I use function like this:
Function StrQuoteReplace(strValue)
// Replace any double quote in strValue with one single quote.
// The second argument to Replace consists of
// one double quote enclosed in a pair of double quotes.
// The third argument to Replace consists of
// one single quote enclosed in a pair of double quotes.
StrQuoteReplace = Replace(strValue, " " ", " ' "
End Function
but I don't know for some reason the code does not work, I have a compile
error, the message is in the following:
"Microsoft VBScript compilation error '800a03ee'
Expected ')'
StrQuoteReplace = Replace(strValue, """, "'"
------------------------------------------^"
Any Suggestions will be most welcome.
Thanks in advance
Henry
I have a funny experience. In a case I want to replace all double quotes in
my data content by single quotes. I use function like this:
Function StrQuoteReplace(strValue)
// Replace any double quote in strValue with one single quote.
// The second argument to Replace consists of
// one double quote enclosed in a pair of double quotes.
// The third argument to Replace consists of
// one single quote enclosed in a pair of double quotes.
StrQuoteReplace = Replace(strValue, " " ", " ' "
End Function
but I don't know for some reason the code does not work, I have a compile
error, the message is in the following:
"Microsoft VBScript compilation error '800a03ee'
Expected ')'
StrQuoteReplace = Replace(strValue, """, "'"
------------------------------------------^"
Any Suggestions will be most welcome.
Thanks in advance
Henry