Page 1 of 1

String Substitution for a tilde

Posted: 26 Feb 2009 12:55
by toshiro
I'd like to find and change

yahoo~com

to

yahoo.com

but when I try string substitution, I think it's getting crossed up w/string indexing. I tried escaping the tilde, but no dice. Tried the quoted everything method, but same result. Any tricks I might be missing?

Thanks,

Tom

Replace tilde

Posted: 26 Feb 2009 17:43
by suitto
Hi Toshiro,
I tried this and it seemed to work for a tilde.
Doesn't work for me when its an equal sign

set str=simple equation yahoo~com
echo.%str%
set str=%str:o~c=o.c%
echo.%str%