Specifically lets say i create a list with :
for {set i 0} {$i < $val(recv)} {incr i} {
lappend bwList "videoBW_($i).tr"
close $videoBW_($i)
}
and then i want to give that list as an argument of multiple files with
exec xgraph $bwList -geometry 800x400 &
It will give me the error:
Warning: cannot open file `videoBW_(0).tr videoBW_(1).tr videoBW_(2).tr'
Because tcl reads the whole list as one string instead of multiple strings. Is there a way to read the list as multiple strings ?
EDIT :
The solution for tcl8.4 is the one Brian Fenton provided. but by changing set exec_call {xgraph $bwList -geometry 800x400} to set exec_call "xgraph $bwList -geometry 800x400"
Basically if you only add eval in front of exec it does the job .
eval exec xgraph $bwList -geometry 800x400 &
Fot tcl 8.5 Bryan Oakley provided a more elegant solution.