hi everyone....... i am writing a program where i have 2 ovals and i want my first oval to appear then after 2 seconds the second one...but am failing in doing this.
can anyone help me to do this please. thank you in advance
here is my code
from Tkinter import * import Tkinter import time import thread frame=Tkinter.Frame() frame.pack() canvas =Tkinter.Canvas(frame,bg = 'white',width=500, height=500) canvas.pack() def generate(): canvas.create_oval(200,300,210,310) #my first oval time.sleep(2) canvas.create_oval(200,300,210,310) # my second oval button=Tkinter.Button(frame,fg="blue", text="GENERATE", command=generate).pack() mainloop()
the problem that i'm having with this is that the computer is waiting for 2 sec then displays both oval but me i want 1 at a time.....
someone please help me in doing this