Tkinter slide question
Fred L. Drake
fdrake at cnri.reston.va.us
Tue Jun 29 20:31:50 CEST 1999
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