OptionMenu Widget
In this lesson, we will learn to create an OptionMenu widget for reading data from users.
We'll cover the following...
We'll cover the following...
The OptionMenu widget can display a group of values when clicked. The user can select only one option from this set of values. It is also called a drop-down menu.
Let’s see how we can create an OptionMenu in Tkinter.
Creating OptionMenu widgets
The syntax for creating an OptionMenu widget is as follows:
myOptionMenu = tk.OptionMenu(parent, variable, default=None, *values)
The ...