[Tutor] commands with multiple things to do?
Alan Gauld
alan.gauld at freenet.co.uk
Tue Mar 29 19:27:06 CEST 2005
> Is it possible for me to make a command do multiple things instead
of 1?
Yes, its called writing a function or method.
> self.submit_bttn = Button(self, text = "Tries: 0", command =
self.reveal, self.update_count)
> I have tried putting the code as 2 commands on separate lines,
Try putting the call to self_update inside self.reveal.
Or if reveal gets called elsewhere as well then define a new method
called say, self.revealAndUpdate that calls both.
Alan G.
More information about the Tutor
mailing list