Very practical question
Simon Forman
rogue_pedro at yahoo.com
Thu Jul 6 12:39:06 EDT 2006
madpython wrote:
> ...
> self.b=Tkinter.Button(root,txt="Button",command=self.doSmth).pack()
> self.l=Tkinter.Label(root,txt="default").pack()
> def doSmth(self):
> var=globals()["m"].__dict__["progLogic"].func("some
> input")
> self.l.config(txt=var)
> self.l.update_idletasks()
> ...
pack() method returns None, *not* the packed widget.
>>> import Tkinter
>>> b = Tkinter.Button()
>>> n = b.pack()
>>> n
>>> print n
None
More information about the Python-list
mailing list