Tkinter slide question
Fred L. Drake
Fred.L..Drake at p98.f112.n480.z2.fidonet.org
Tue Jun 29 14:31:50 EDT 1999
From: "Fred L. Drake" <fdrake at cnri.reston.va.us>
David Stokes writes:
> Code snipit:
> currently returns PY_VAR12 instead of the slider value.
Appearantly, you're refering to self.yspeed to get the value of the
variable, although you seem to have initialized self.yspeed with an
instance of Tkinter.StringVar or one of it's friends.
To get the value, use self.yspeed.get(); the object itself is simply
a reference to a Tcl variable. The get() method will return the value
as the data type indicated by the name of the class you instantiated
to create self.yspeed.
Fred L. Drake, Jr. <fdrake at acm.org>
Corporation for National Research Initiatives
More information about the Python-list