我正在尝试在 Python 3.8 上制作一个待办事项列表程序。它将在以下方面获取用户的输入
def input_(): label["text"] = inputword.get() inputword=Entry() inputword.pack(anchor = "nw", padx = 10, pady = 10)
和一个按钮:
add_input= Button(text ="Add to List", command = input_, bg = "#ae0000", fg= "white", font=("Calibri", "15", "bold") ) add_input.pack(anchor="nw", padx=10)
这有效,但我无法将我的输入添加到列表中。
listbox=Listbox() listbox.place(x=250,y=250) listbox.insert(0, add_input or maybe input_)
我应该如何重新排列我的代码?
繁华开满天机
相关分类