| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
| |||
| |||
| when i do the following proc proc complang {} { set url "http://groups.google.fr/group/comp.lang.tcl/topics" eval exec [auto_execok start][list $url] "&" } i open firefox and get comp.lang.tcl all right when i do the same to get fr.comp.lang.tc proc compfr {} { set url " http://groups.google.fr/group/fr.comp.lang.tcl/topics " eval exec [auto_execok start ][list $url] "&" } i get vista console ????? apparently both are the same and do not give the same result ?? maybe it is late and i did not see an obious mistake in coding. If so i apologize. If not thank you in advance for any advice jerome |
|
#2
| |||
| |||
| groupeCompteRendu@gmail.com wrote: > when i do the following proc > > proc complang {} { > set url "http://groups.google.fr/group/comp.lang.tcl/topics" > eval exec [auto_execok start][list $url] "&" > } > > i open firefox and get comp.lang.tcl all right > > when i do the same to get fr.comp.lang.tc > > proc compfr {} { > set url " http://groups.google.fr/group/fr.comp.lang.tcl/topics " > eval exec [auto_execok start ][list $url] "&" > } > > i get vista console ????? Why do you have a leading and trailing space in your second example? -- | Don Porter Mathematical and Computational Sciences Division | | donald.porter@nist.gov Information Technology Laboratory | | http://math.nist.gov/~DPorter/ NIST | |_________________________________________________ _____________________| |
|
#3
| |||
| |||
| On Nov 5, 10:43*pm, groupeCompteRe...@gmail.com wrote: > when i do the following proc > > proc complang {} { > set url *"http://groups.google.fr/group/comp.lang.tcl/topics" > *eval exec [auto_execok start][list $url] "&" > > } > > i open firefox and get comp.lang.tcl all right > > when i do the same to get fr.comp.lang.tc > > proc compfr {} { > set url *"http://groups.google.fr/group/fr.comp.lang.tcl/topics" > *eval exec [auto_execok start *][list $url] "&" > > } > > i get vista console ????? > > apparently both are the same and do not give the same result ?? > > maybe it is late and i did not see an obious mistake in coding. *If > so i apologize. *If not thank you in advance for any advice > jerome Start is a bit peculiar when encountering arguments with spaces, it will then interpret it as a window title. The 'correct' way to call start is almost always: eval exec [auto_execok start] ""[list $url] "&" or in 8.5: exec {*}[auto_execok start] "" $url & But even this will fail when $url contains for instance ampersands. See http://wiki.tcl.tk/start for more details and for a really robust way to start a process on win32 (using TWAPI) Mark |
|
#4
| |||
| |||
| On 5 nov, 22:52, Don Porter <d...@nist.gov> wrote: > groupeCompteRe...@gmail.com wrote: > > when i do the following proc > > > proc complang {} { > > set url *"http://groups.google.fr/group/comp.lang.tcl/topics" > > *eval exec [auto_execok start][list $url] "&" > > } > > > i open firefox and get comp.lang.tcl all right > > > when i do the same to get fr.comp.lang.tc > > > proc compfr {} { > > set url *"http://groups.google.fr/group/fr.comp.lang.tcl/topics" > > *eval exec [auto_execok start *][list $url] "&" > > } > > > i get vista console ????? > > Why do you have a leading and trailing space in your second example? > > -- > | Don Porter * * * * *Mathematical and Computational Sciences Division | > | donald.por...@nist.gov * * * * * * Information Technology Laboratory | > |http://math.nist.gov/~DPorter/* * * * * * * * * * * * * * * * *NIST | > |_________________________________________________ _____________________| Hello thanks to you and Mark for helping and now it works. friendly jerome |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.