Hello, I'm trying to implement a loop in a Tcl interpreter from Perl code but I'm finding some problems (maybe related with my un-expertise in TCL :). For example, I'm trying to implement this simple TCL loop:
foreach i {1 2 3} { puts $i } I've tried (in Perl): use Tcl; $i = new Tcl; $i->Eval('"foreach i {1 2 3} {'); $i->Eval(' puts $i'); $i->Eval('}'); but the result is: tornado:~# perl /tmp/foo missing close-brace at /tmp/kk line 3. Of course, the following works fine in this case: use Tcl; $i = new Tcl; $i->Eval('foreach i {1 2 3} { puts $i }'); but this solution only is fine for one-command loops. How can I implemented a TCL loop in general using Perl Tcl module? (Maybe this question is a bit silly, but I'm quite newbie in Perl Tcl and TCL in general. Please, forgive me! :) Thanks you very much in advance! Best regards, -------------------- Fermín Galán Márquez CTTC - Centre Tecnològic de Telecomunicacions de Catalunya Parc Mediterrani de la Tecnologia, Av. del Canal Olímpic s/n, 08860 Castelldefels, Spain Room 1.02 Tel : +34 93 645 29 12 Fax : +34 93 645 29 01 Email address: [EMAIL PROTECTED]