I need to create a choice box
where i can click on arrow and it give me list of choices.
And if i click on one of them it will change it in that first rectangle.
Its possible to do something like this?
Thank you for any idea.
You can also try an OptionMenu
:
from Tkinter import *
root = Tk()
choices = ['GB', 'MB', 'KB']
variable = StringVar(root)
variable.set('GB')
w = OptionMenu(root, variable, *choices)
w.pack(); root.mainloop()
Or you can try using a Combobox
:
from ttk import *
from Tkinter import *
root = Tk()
choices = ['GB', 'MB', 'KB']
variable = StringVar(root)
variable.set('GB')
w = Combobox(root, values = choices)
w.pack(); root.mainloop()