1
我試圖在Python中使用Tkinter創建一個Spin-box,其中包含當月的日子(字符串),但只知道如何將數字包含在範圍。例如。; from_ = 1900, to = 2016
。如何在Python中使用Spinbox包含變量列表Tkinter
如何在旋轉框中包含字符串列表?我是否需要創建一個實際的列表?
下面是具體代碼:
w = StringVar()
Spinbox(root, from_ = 1900, to = 2017, textvariable = w, width = 5).place(x = 315, y = 60)