<[EMAIL PROTECTED]> escribió en el mensaje
news:[EMAIL PROTECTED]
> button[num] = Tkinter.Button(frame,text = returnstring,
> command=callback(returnstring))#
>
> I understand this part of it
>
> def callback(text):
> def handler(event):
> print text
> It stopped calling it automaticaly b
[EMAIL PROTECTED] wrote:
> Scott David Daniels wrote:
>> Gabriel Genellina wrote:
>> >... So `callback` should return a function, like this:
>> >
>> > def callback(text):
>> > def handler(event):
>> > print text
>> >
>>
>> Even better than that:
>> def callback(text):
>> def ha
> button[num] = Tkinter.Button(frame,text = returnstring,
> command=callback(returnstring))#
I understand this part of it
def callback(text):
def handler(event):
print text
It stopped calling it automaticaly but will not do anything when I
click on the button. Does something have to cha
C:\dex_tracker\csdlist.py bay-at-night.csd
Traceback (most recent call last):
File "C:\dex_tracker\csdlist.py", line 58, in
root.mainloop()
File "C:\Python25\lib\lib-tk\Tkinter.py", line 1023, in mainloop
self.tk.mainloop(n)
File "../../..\Pmw\Pmw_1_2\lib\PmwBase.py", line 1751, in __call__
Fil
Gabriel Genellina wrote:
>... So `callback` should return a function, like this:
>
> def callback(text):
> def handler(event):
> print text
>
Even better than that:
def callback(text):
def handler(event):
print text
return handler
Otherwise callback ret
<[EMAIL PROTECTED]> escribió en el mensaje
news:[EMAIL PROTECTED]
> Instead of creating my buttons and waiting for me to press them to
> execute they are executing when I create them and won't do my callback
> when I press them.. thanks for any help in advance
This is a very frequent beginner's
Instead of creating my buttons and waiting for me to press them to
execute they are executing when I create them and won't do my callback
when I press them.. thanks for any help in advance
button[num] = Tkinter.Button(frame,text = returnstring,
command=callback(returnstring))#
this line execute