我一直收到以下错误:AttributeError:'NoneType'对象没有属性'configure'
# create color button
self.button = Button(self,
text = "Click Me",
command = self.color_change,
bg = "blue"
).grid(row = 2, column = 2, sticky = W)
def color_change(self):
"""Changes the button's color"""
self.button.configure(bg = "red")
Run Code Online (Sandbox Code Playgroud)