Re: Hide text in entry box when i click on it.(GUI using Tkinter in python)

2019-05-31 Thread sakshamraheja11
Not happening in mine
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: Hide text in entry box when i click on it.(GUI using Tkinter in python)

2019-05-31 Thread sakshamraheja11
NOT WORKING IN MINE PLZ HELP



from tkinter import *
g=Tk()
g.geometry("{0}x{1}+0+0".format(g.winfo_screenwidth(), g.winfo_screenheight()))
g.title("Check")
g.configure(background='powder blue')


def clear_search(event): 
e1.delete(0, tk.END) 

e1=Entry(g)
e1.insert(0,'username')
e1.pack()
e1.bind("", clear_search)
e1.bind("", clear_search)

g.mainloop()
-- 
https://mail.python.org/mailman/listinfo/python-list