Advertisement
here2share

# Tk_spinbox.py

Jul 31st, 2016
179
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.27 KB | None | 0 0
  1. # Tk_spinbox.py
  2. from Tkinter import *
  3.  
  4. root = Tk()
  5. root.geometry('100x50+50+50')
  6. root.title('Spinbox')
  7.  
  8. t = ('One', 'Two', 'Three', 'Four', 'Five')
  9. v = t[2]
  10.  
  11. var = StringVar()
  12. sb = Spinbox(root, values=t, textvariable=var, width=16)
  13. var.set(v)
  14. sb.place(x=5, y=15)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement