from guizero import App, TextBox, PushButton, Text, info app = App() def btn_go_clicked(): info("Greetings","Hello, " + txt_name.value + " - Use this form to enter a password and confirm it") def btn_check_clicked(): if txt_password_1.value == txt_password_2.value: info("Confirmation", "Match!") else: info("Confirmation", "No match!") lbl_name = Text(app, text="Hello. What's your name?") txt_name = TextBox(app) lbl_password_1 = Text(app, text="\nEnter your password to the electronic cookie jar") txt_password_1 = TextBox(app) lbl_password_2 = Text(app, text="Enter your password to the electronic cookie jar again to confirm") txt_password_2 = TextBox(app) btn_go = PushButton(app, command=btn_go_clicked, text="Done") btn_check = PushButton(app, command=btn_check_clicked, text="Check passwords match") app.display()