Notices
Computer & Technology Related Post here for help and discussion of computing and related technology. Internet, TVs, phones, consoles, computers, tablets and any other gadgets.

any ASP gurus out there?

Thread Tools
 
Search this Thread
 
Old 07 March 2002, 12:41 PM
  #1  
Richard.S
Scooby Regular
Thread Starter
 
Richard.S's Avatar
 
Join Date: Feb 2002
Posts: 232
Likes: 0
Received 0 Likes on 0 Posts
Talking

Does anyone know how to replace double quotes in ASP?

3,4,5,6 of them don't work...

Trying to insert into an SQL database:


for x = 1 to Len(form_q27)

if mid(form_q27,x,1)=" then

form_q27=left(form_q27,x-1) + "#" + right(form_q27, (Len(form_q27) -x))

end if


cheers m'dears

[Edited by Richard.S - 7/3/2002 12:44:08 PM]
Old 03 July 2002, 01:18 PM
  #2  
Dream Weaver
Scooby Regular
 
Dream Weaver's Avatar
 
Join Date: Feb 2000
Location: Lancashire
Posts: 9,844
Received 0 Likes on 0 Posts
Question

What do you want to replace them with? Just remove them I presume from a form input?

DW
Old 03 July 2002, 01:48 PM
  #3  
David_Wallis
Scooby Regular
 
David_Wallis's Avatar
 
Join Date: Nov 2001
Location: Leeds - It was 562.4bhp@28psi on Optimax, How much closer to 600 with race fuel and a bigger turbo?
Posts: 15,239
Likes: 0
Received 1 Like on 1 Post
Post

use chr(34)

david
Old 03 July 2002, 02:08 PM
  #4  
Richard.S
Scooby Regular
Thread Starter
 
Richard.S's Avatar
 
Join Date: Feb 2002
Posts: 232
Likes: 0
Received 0 Likes on 0 Posts
Talking

yes, what like this:

form_q25=replace (request.form("q25"),chr(34),"`")
form_q25=replace (form_q25,"'","`")
form_q27=replace (request.form("q27"),chr(34),"`")
form_q27=replace (form_q27,"'","`")

but did this finally:

use \" if you want to represent a double quote inside a set of quotes. So if you're looking for this string- mary said "bollox"
you would use:-

if string=="mary said\"bollox\"" then ....

cheers anyway!
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
Darrell@Scoobyworx
Trader Announcements
26
30 January 2024 01:27 PM
ozzy
Scotland
6
24 October 2001 01:04 PM
Mojo
Non Scooby Related
8
24 August 2001 09:56 AM
mega_stream
Non Scooby Related
2
09 August 2001 07:51 PM



Quick Reply: any ASP gurus out there?



All times are GMT +1. The time now is 07:47 PM.