|
From: Gregory P. <gp...@ls...> - 2005-03-04 14:30:54
|
Hi,
The following regular expression substitution will work fine:
set path {C:/how/to/change/the/path/delimiter}
regsub -all {\\} $path newpath
puts $newpath
You could put this into a procedure too:
proc chgpath { path } {
regsub -all {\\} $path newpath
return $newpath
}
set newpath [ chgpath $path ]
Hope this helps...
Greg
M.Srinivasa Rao wrote:
>How to convert the forward slashes to backward slashes using Tcl? I need to
>replace the "/" with "\\".
>
>In windows when I am sending the file along with path which contains the
>forward slashes to printer , I am not able to get the print.
>
>With Regards,
>Srinivas
>
>
>
>-------------------------------------------------------
>SF email is sponsored by - The IT Product Guide
>Read honest & candid reviews on hundreds of IT Products from real users.
>Discover which products truly live up to the hype. Start reading now.
>http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
>_______________________________________________
>Tcl-win mailing list
>Tc...@li...
>https://lists.sourceforge.net/lists/listinfo/tcl-win
>
>
>
>
|