[Tutor] GUI Buttons
Alan Gauld
alan.gauld at btinternet.com
Tue Oct 13 10:06:50 CEST 2009
Please provide a subject when sending mail to the list.
And please create a new message so it doesn't get lost in an old thread...
"Albert-Jan Roskam" <fomcl at yahoo.com> wrote in message
> I'm using Tkinter to program my very frist GUI.
> Each button grays out after it has been used so the user knows what next
> steps to take.
> Now I want to define a Reset button to 'ungray' all buttons
> (state='normal').
> How can I programmatically create a list of all available buttons?
Just add your buttons to a list when you create them
Then in your reset method do
for button in ButtonList:
button['state'] = NORMAL
HTH,
--
Alan Gauld
Author of the Learn to Program web site
http://www.alan-g.me.uk/
More information about the Tutor
mailing list