📜  带参数的 tkinter 按钮命令 - Python 代码示例

📅  最后修改于: 2022-03-11 14:47:16.252000             🧑  作者: Mango

代码示例2
from functools import partial
#
#
def function_name(arg1):
    print(arg1)
#
#tkinter codes for GUI
#
buttonExample = tk.Button(main, text="Button", command=partial(function_name, argument1))