[Tutor] Tkinter OptionMenu question

Neil Hodge hodge3@llnl.gov
Thu Jun 5 11:37:00 2003


All:

I was wondering if anyone here knows how to change the items in a 
Tkinter OptionMenu after it's initial creation.  I am using the 
following code to create the menu initially:

strvar = StringVar()
test = ("none", "item1", "item2", "item3")
strvar.set(test[0])
om = OptionMenu(self, strvar, *test)

and that works fine.  But I would like my OptionMenu to later look like 
the following:

none
itemx
itemy
itemz

I have tried everything that I can think of (after reading all of the 
docs I could find), but nothing works.  Any ideas?  Thanks.

Neil