Forum Moderators: open

Message Too Old, No Replies

ASP Find

I've just realised I don't know the command.

         

chris_f

9:53 am on Jan 22, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi Guys,

I always use the replace command in ASP like below:

SomeVariable = Replace(SomeOtherVariable, " ", "_")

But I have just realised that I don't know the find command. Does anyone know it. If not, I could do the following.

ReplacedString = Replace(OriginalString, StingToFind, "1234567890")
If ReplacedString = OriginalSting Then
'Its not in there
Else
'Its in there
End If

Any ideas?
Chris

Woz

10:05 am on Jan 22, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



If inStr(1, OriginalString, StringToFind) > 0 then
it is there
else
it is not
end if

Onya
Woz

chris_f

10:15 am on Jan 22, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Cheers WOZ,

A much easier solution. I can't believe I gone several years and NEVER had to use a find command.

Chris

p.s. what does ONYA mean again? I keep forgetting.

Woz

10:18 am on Jan 22, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Aussie Slang.

Good On You = G'donya = Onya

er, something
Woz