The purpose of this widget is to offer a fixed set of choices to the user in a drop-down menu.
Questions tagged [tkinter.optionmenu]
66 questions
0
votes
1 answer
How do I add new options, and then read the new selected option in a python tkinter optionMenu?
With the code I currently have, when the program starts, I can select from 3 options, and have that option printed to the console. I can also have text entered into the text entry, be added to the optionMenu list by pressing the button.
By adding…

ShaunBach
- 31
- 1
- 4
0
votes
1 answer
Python tkinter cut down path but open as full directory
Here is my full Python code:
from tkinter import *
import glob
import os
from PIL import Image, ImageTk, ImageGrab
import tkinter as tk
import pyautogui
import datetime
#date & time
now = datetime.datetime.now()
root = tk.Tk()
root.title("SIGN…
user11294454
-1
votes
1 answer
How to assign user selected color to every element in a list in Python using tkinter
I am trying to plot signals on a graph. I need a feature where the list of signals selected by user for plotting is assigned a specific color chosen by the user himself.
I need to generate such a GUI window using tkinter in Python which allows me to…

Surabhi Zadoo
- 1
- 1
-1
votes
2 answers
How to get tkinter OptionMenu to display the name of the selected option?
In tkinter, I have created an option menu using the OptionMenu class. As an example, the OptionMenu below has options A, B, C, D, etc.:
self.clicked = tk.StringVar(self.parent)
self.clicked.set("Select Column")
self.drop =…

ephemeralhappiness
- 67
- 1
- 14
-1
votes
1 answer
Tkinter Option Menu Variable.get() method not returning selected element
I have some problems with Tkinter, I want so retrieve the selected item of an option menu when pressing a button, but when testing the funcionality with a small testfuntion 'getdataset', I only get the predefined datavariable ('Birthdata') as an…

K_Luijten
- 3
- 1