Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from tkinter import *
- class Main:
- def __init__(self):
- main = Tk()
- self.x = 0
- Button(main,text=self.x,command=self.xplus1()).pack()
- Button(main,text='Quit',command=main.destroy ).pack()
- mainloop()
- def xplus1(self):
- self.x = self.x + 1
- Main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement