Probems with Replace Command

J

Jimmy

Hi,

I am facing problems with the replace command in classic ASP.

my code is as follows:
..........
test = Replace(test,"xxxx/xxxxxxxxxx","yyy/yyyyy",,,1)
..........


I want to use compare method as vbTextCompare i.e. 1
When I remove this parameter, it works fine.

the error is as follows:
Microsoft VBScript runtime error '800a000d'
Type mismatch


Can someone kindly help me out with this

Thanks in advance
 
M

McKirahan

Jimmy said:
Hi,

I am facing problems with the replace command in classic ASP.

my code is as follows:
.........
test = Replace(test,"xxxx/xxxxxxxxxx","yyy/yyyyy",,,1)
.........


I want to use compare method as vbTextCompare i.e. 1
When I remove this parameter, it works fine.

the error is as follows:
Microsoft VBScript runtime error '800a000d'
Type mismatch


Can someone kindly help me out with this

Thanks in advance

What a value of the variable "test"?

We need to simulate/duplicate your problem.
 
J

Jimmy

Hi ,

Thanks for looking in to the issue.
I was able to resolve the error I used the following code:

test = Replace(test,"xxxx/xxxxxxxxxx"­,"yyy/yyyyy",1,-1,1)

By The way, the value of test was HTML Content
Thanks Again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top