Radio buttons, the easy way : Radiobutton : Tkinker PYTHON TUTORIALS


PYTHON TUTORIALS » Tkinker » Radiobutton »

 

Radio buttons, the easy way


Radio buttons, the easy way
from Tkinter import *      
root = Tk()                    
var  = IntVar()                
for i in range(10):
    rad = Radiobutton(root, text=str(i), value=i, variable=var)
    rad.pack(side=LEFT)
root.mainloop()
print var.get()



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo Tkinker
» Radiobutton