Access from one class to methode of other class
VK
"myname" at example.invalid
Thu May 26 08:33:45 EDT 2005
Hi, all!
In my programm i have to insert a variable from class 2 to class 1 and I
get error NameError: global name 'd' is not defined. How do I get access
to d.entry.insert() method of class 1
class 1:
self.entry = Entry(self.entryframe)
self.entry.pack()
self.button = Button(command = self.callclass2window)
def callclass2window
c = 2()
class 2:
def ins(self)
d.entry.insert(variable)
d = 1()
More information about the Python-list
mailing list