楼主:
IAMPF (PF)
2015-12-20 12:25:09各位大大们好
最近在研究Tkinter写视窗程式,遇到一个问题
比如我今天创一个Button
def a():
print 'Hello'
b = Button(root, text='click', command=a)
问题就在这个command=a
通常a这个function不能带参数
有办法写一个a是可以传参数进去的吗
比如
def a(arg1, arg2):
print arg1, arg2
不知道要改的地方是在Button那边还是说在a那边