Hello,
I need to display a listbox of a list variable crated with with lappend (cliste). The command "puts" shows the rows enclosed in brackets {} but I cant get the list displayed in the listbox.
Please check the command: .m_outp.lb $cliste in my code.
Can I have some advise please ?
proc Create_output {cliste} {
toplevel .m_outp
frame .m_outp.f
listbox .m_outp.lb -selectmode single -height 10
scrollbar .m_outp.sb -command [list .m_outp.lb yview]
.m_outp.lb configure -yscrollcommand [list .m_outp.sb set]
.m_outp.lb $cliste
pack .m_outp.lb .m_outp.sb -in .m_outp.f -side left -expand 1 -fill both
grid .m_outp.f
bind .m_outp.lb <ButtonPress-1> {exit}
}
I need to display a listbox of a list variable crated with with lappend (cliste). The command "puts" shows the rows enclosed in brackets {} but I cant get the list displayed in the listbox.
Please check the command: .m_outp.lb $cliste in my code.
Can I have some advise please ?
proc Create_output {cliste} {
toplevel .m_outp
frame .m_outp.f
listbox .m_outp.lb -selectmode single -height 10
scrollbar .m_outp.sb -command [list .m_outp.lb yview]
.m_outp.lb configure -yscrollcommand [list .m_outp.sb set]
.m_outp.lb $cliste
pack .m_outp.lb .m_outp.sb -in .m_outp.f -side left -expand 1 -fill both
grid .m_outp.f
bind .m_outp.lb <ButtonPress-1> {exit}
}