Advertisement
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_password1.value == txt_password2.value:
- info("Match","The passwords match")
- else:
- info("No match", "The passwords don't match, please enter them again.")
- # Your GUI widgets go here
- lbl_password1 = Text(app, text="Please enter your new password.")
- txt_password1 = TextBox(app)
- lbl_password2 = Text(app, text="Please enter your password again")
- txt_password2 = TextBox(app)
- btn_go = PushButton(app, command=btn_go_clicked, text="Done")
- # Show the GUI on the screen
- app.display()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement