Skip to content

Show password is not working #597

Answered by abhaymakes
Hancie123 asked this question in Q&A
Discussion options

You must be logged in to vote

Here is the updated code :

import customtkinter as c

root = c.CTk()


def show_password():
  if i.get() == 1:
    e.configure(show='')
  else:
    e.configure(show='*')



e = c.CTkEntry(root, show="*")
e.pack()

i = c.IntVar()

password_show = (root, text="Show password", variable=i, command=show_password)
password_show.pack()


root.mainloop()

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Hancie123
Comment options

Answer selected by Hancie123
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants