how best to clear objects from a frame

Chris Hare chare at labr.net
Mon Aug 2 22:17:36 CEST 2010


On Aug 1, 2010, at 10:13 PM, rantingrick wrote:

> On Aug 1, 7:12 pm, Chris Hare <ch... at labr.net> wrote:
>> Here is the situation:
>> 
>> I have a window with a bunch of widgets in it.  I want to clear the objects in a given frame and recreate them to update them.  
> 
> You need to check out the "w.update" and "w.update_idletasks" methods
> available on all Tkinter widgets. Just FYI: to remove a widget from
> view without destroying it use "w.pack_forget" or "w.grid_forget".
> However if you are simply trying to refresh a widget use one of the
> update methods.
> -- 
> http://mail.python.org/mailman/listinfo/python-list

I will have a look at those.  Consider a frame with a label and a button.  How do I address the label to change it from another function in the class?  




More information about the Python-list mailing list