Tkinter wm_withdraw doesn't work

Theodore D. Sternberg strnbrg at
Sat May 19 23:08:39 CEST 2001

Anyone know the correct way to translate the Tk-ism "wm withdraw ."
to Python/Tkinter?

As far as I can see, the implementation of the Wm class' wm_withdraw
function tries to call a nonexistent member function called "tk()":

I executed the following file:

--------- file ------
from Tkinter import *

root = Tk() 

wm = Wm()


...and obtained the following result:

$ python
Traceback (most recent call last):
  File "", line 7, in ?
  File "/usr/local/lib/python2.1/lib-tk/", line 1457, in wm_withdraw
    return'wm', 'withdraw', self._w)
AttributeError: Wm instance has no attribute 'tk'

More information about the Python-list mailing list