For Programmers: Free Programming Magazines  


Home > Archive > Tcl > June 2007 > Re: Stripping characters from a string









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: Stripping characters from a string
TronyQ

2007-06-26, 8:09 am

On Jun 25, 4:26 pm, tcltk...@aol.com wrote:
> Is there a shorter way of stripping characters from a string?
>
> Original: "the quick *brown fox (jumps) over the lazy dog!"
>
> Strpped: "the quick brown fox jumps over the lazy dog"



regsub -all {[^\w\s]} $string {} newstring

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com