Hello all I am a python "n00b", however I can't find a solution to this problem anywhere.
I am using a simple setup - entry box, button and list box, the contents of the entry being inserted into the list box: from Tkinter import * def insert(): name = ent.get() box.insert(0, name) ent.delete(0, END) root = Tk() ent = Entry(root, fg = '#3a3a3a', bg = 'white', relief = 'groove').grid(row = 0, padx = 3, pady = 3) button = Button(root, text = "Remember", command = insert, relief = 'groove', fg = '#3a3a3a').grid(row = 0, column = 1, padx = 3, pady = 3) box = Listbox(root, bg = '#ebe9ed', relief = 'groove').grid(row = 2, columnspan = 2, sticky = W+E, padx = 3) root.mainloop() When I type something and press the button, i get this error: Exception in Tkinter callback Traceback (most recent call last): File "C:\Python25\lib\lib-tk\Tkinter.py", line 1403, in __call__ return self.func(*args) File "C:\My Documents\My Python\Notes.py", line 6, in insert name = ent.get() AttributeError: 'NoneType' object has no attribute 'get' I am puzzled as to the last line... Help? Sam -- I intend to live forever - so far, so good. SaM
-- http://mail.python.org/mailman/listinfo/python-list