I found that only converting the file to "short name" works reliably on windows:
## Start arbitrary URL in external program (Windows only)
proc Start {url} {
## try file short name (that is the only way to deal with spaces that works)
if {[catch {file attributes $url -shortname} c]} {set c $url}
catch { exec cmd /C start $c & }
}
Any other methods, like multiple quotes, don't seem to work.
By Anonymous (not verified) at Wed, 2008-11-12 01:50
Try this code
I found that only converting the file to "short name" works reliably on windows:
## Start arbitrary URL in external program (Windows only) proc Start {url} { ## try file short name (that is the only way to deal with spaces that works) if {[catch {file attributes $url -shortname} c]} {set c $url} catch { exec cmd /C start $c & } }Any other methods, like multiple quotes, don't seem to work.