[Tutor] GUI not responding

FxItAL@aol.com FxItAL@aol.com
Thu, 24 Aug 2000 10:45:53 EDT


Hello All,

I have a GUI that accepts Input from the user when the function "ActionBut" is called.  My problem is, even though the program runs on the DOS screen the GUI locks up unitl the "while" loop ends. Any advice is greatly appreciated, Thanks Al

Here's what is causing the lock up:

def ActionButCmd():
    global ClockMin, ClockHour, InputMin, InputHour, var
    var = UserEntry.get()
    Hour_Min=localtime(time())
    ClockMin=Hour_Min[4] 
    ClockHour=Hour_Min[3] 
    InputMin=var
    InputHour=Hour_Min[3]
    if ClockMin<InputMin:
        while ClockMin<InputMin:       
            sleep(5)
            Hour_Min=localtime(time())                              ClockMin=Hour_Min[4]
            ClockHour=Hour_Min[3]            
            print "Great"
    if ClockMin>=InputMin:
        print "END"