Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Import the GUI widgets that you'll be using, and create the 'app' for your program.
- from guizero import App, TextBox, PushButton, Text, info
- app = App()
- # Function definitions for your events go here.
- def btn_go_clicked():
- if txt_passwd.value == txt2_passwd.value :
- info("Password Match","Your password " + txt_passwd.value + ' is OK')
- else:
- info('no match', 'Passwords do not match')
- # Your GUI widgets go here
- lbl_passwd = Text(app, text="Enter your password")
- txt_passwd = TextBox(app)
- lbl2_passwd = Text(app, text="renter your password")
- txt2_passwd = TextBox(app)
- btn_go = PushButton(app, command=btn_go_clicked, text="Submit Password")
- # Show the GUI on the screen
- app.display()
Add Comment
Please, Sign In to add comment