newbie problems with Tkinter

Peter Wichert pwanon at web.de
Mon Jul 22 17:09:43 EDT 2002


Hi group,

I installed python 2.2.1 on my freebsd4.5 and tried some examples from my 
new python-book. But I couldn't get it running.

1) Using module "Tkinter" is the first problem. Doing it twice seems to be 
better:

>>> import Tkinter
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
  File "/usr/local/lib/python2.2/lib-tk/Tkinter.py", line 35, in ?
ImportError: No module named _tkinter
>>> import Tkinter
>>>

2) After that, the book says "tk=Tkinter.Tk()", but I get

>>> tk=Tkinter.Tk()
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
AttributeError: 'module' object has no attribute 'Tk'
>>>

That's all. Please help me.
Peter

-- 
Peter Wichert
pwanon at web.de



More information about the Python-list mailing list