[Tutor] Tkinter entry box text changed event
Phil
phil_lor at bigpond.com
Mon Apr 10 05:34:05 EDT 2017
On Mon, 10 Apr 2017 19:40:01 +0100
Alan Gauld via Tutor <tutor at python.org> wrote:
> You want two parameters
> self becaiuse its a method of a class so must have a self
> event which is the event passsed by the GUI
> So:
>
> def my_method(self, event):
> print("method called with ",event)
>
>
> > I must be close, surely.
>
> A comma instead of a dot...
>
Thank you so much for your patience Alan.
I woke during the early hours thinking about the requirement for two parameters and realised that my other methods only have self as a single parameter and wondered if "event" was the other parameter. I hadn't though of printing the event.
Take no notice of this message's posting time, I started my Raspberry Pi before the modem had established an Internet connection. It's pre sunrise here.
--
Regards,
Phil
More information about the Tutor
mailing list