Forums
This topic is locked
worrying "" problem
25 Apr 2002 14:22:24 Sill Sill posted:
using: ASP VBScript, Access DBIve just discovered a worrying bug or something - It happened when I came to modify a record with a " in it (one of the 66 99 bits) - it was just blank from where one of those started ...
Im modifying this from a form on a webpage, not the db itself.
Anyone else know what this problem is and is there a way around it?
anyhelp would be great
Replies
Replied 25 Apr 2002 14:28:56
25 Apr 2002 14:28:56 Andrew Watson replied:
Its because the double quote character is a delimeter in VBScript and if one occurs in a string then it is interperated as such.
The trick is obviously to not enter any double quotes but to be sure then you can do something like this...
Replace(YourString, chr(34), "'" this will get shot of them, you can replace the " (chr(34)) with whatever you want.
THere are other threads dealing with this in detail,
Cheers
:: Son, im Thirty.... ::
The trick is obviously to not enter any double quotes but to be sure then you can do something like this...
Replace(YourString, chr(34), "'" this will get shot of them, you can replace the " (chr(34)) with whatever you want.
THere are other threads dealing with this in detail,
Cheers
:: Son, im Thirty.... ::
Replied 02 May 2002 12:31:26
02 May 2002 12:31:26 Sill Sill replied:
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
Its because the double quote character is a delimeter in VBScript and if one occurs in a string then it is interperated as such.
The trick is obviously to not enter any double quotes but to be sure then you can do something like this...
Replace(YourString, chr(34), "'" this will get shot of them, you can replace the " (chr(34)) with whatever you want.
THere are other threads dealing with this in detail,
Cheers
:: Son, im Thirty.... ::
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Any idea where these other strings are that discuss this in detail?
Im having trouble finding the problem in the UDZone forums - and also on the iNet and other forums for that matter...
Any chance of providing a link?
Thanks
Its because the double quote character is a delimeter in VBScript and if one occurs in a string then it is interperated as such.
The trick is obviously to not enter any double quotes but to be sure then you can do something like this...
Replace(YourString, chr(34), "'" this will get shot of them, you can replace the " (chr(34)) with whatever you want.
THere are other threads dealing with this in detail,
Cheers
:: Son, im Thirty.... ::
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
Any idea where these other strings are that discuss this in detail?
Im having trouble finding the problem in the UDZone forums - and also on the iNet and other forums for that matter...
Any chance of providing a link?
Thanks