Substitution error?



Hi,

I have a top frame followed by a loop:

*******************************************
set topf [frame $frame.topf]
for {set i 0} {$i < 10} {incr i} {
set a$i [TitleFrame $topf.a$i -text "Title $i"]
pack $a$i
}
*******************************************

But i have an error:
can´t read "a": no such variable while executing pack $a$i

My questions are:
How i can pack this frames/titleframes in a loop "n" times?
What happend with a for-loop in local use of variables in frames/subframes?


Thanks in advance.

Edu


.



Relevant Pages

  • Re: winter hiking
    ... > on the pack and take them off the pack without taking the pack off? ... The pack has got a velcro-closed loop ... The shoes hang off the top loop, ... long parts were light fluffy snow several feet deep. ...
    (rec.backcountry)
  • Re: winter hiking
    ... >> on the pack and take them off the pack without taking the pack off? ... The shoes hang off the top loop, ... > long parts were light fluffy snow several feet deep. ...
    (rec.backcountry)
  • Re: Substitution error?
    ... How i can pack this frames/titleframes in a loop "n" times? ... What happend with a for-loop in local use of variables in frames/subframes? ...
    (comp.lang.tcl)
  • Re: Bug in CS4?
    ... simply have to stay in the loop or pack up and go back to a sketch pad! ... Now I hold out on upgrades as long as possible. ...
    (comp.graphics.apps.photoshop)
  • Re: is it possible to access members of struct in loop?
    ... the foraech construct found in some other languages. ... thank you - i will pack the values in an array and have my loop go ...
    (comp.lang.c)