Advertisement
zhongnaomi

password check gui 5

Jan 1st, 2020
249
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.80 KB | None | 0 0
  1. # Import the GUI widgets that you'll be using, and create the 'app' for your program.
  2. from guizero import App, TextBox, PushButton, Text, info
  3. app = App()
  4.  
  5. # Function definitions for your events go here.
  6. def btn_go_clicked():
  7.     if  password1_name.value!=password2_name.value :
  8.         {
  9.             info("No Match","Password must be the same, try again" )
  10.             }
  11.     else :
  12.         info ("look good", "Your password was set successfully. ")
  13.    
  14.  
  15. # Your GUI widgets go here
  16. lbl_name = Text(app, text="Hello.Please create a new password")
  17. lbl2_name =Text(app, text="Enter your new password")
  18. password1_name = TextBox(app)
  19. lbl3_name =Text(app, text="Enter your new password again")
  20. password2_name =TextBox(app)
  21. btn_go = PushButton(app, command=btn_go_clicked, text="Done")
  22.  
  23. # Show the GUI on the screen
  24. app.display()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement