Lucas Meier Lucas Meier - 1 year ago 59
Python Question

How to use method?

I have a problem using the

Here is the code.

import time

Answer Source

Don't use time.sleep() at all in Tkinter applications. Have the callback schedule a call to itself with after().

def command_Print(counter=0):
    if counter < 10:
        root.after(1000, lambda: command_Print(counter+1))

Also, range(0, 10, 1) is just range(10). There's no need to repeat the defaults.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download