Movatterモバイル変換
[0]ホーム
Problem stopping Tkinter apps
David Fuessfuess at att.net
Sun Apr 1 10:50:16 EDT 2001
Thanks David. That seems to work. I still have a "sys.exit(0)"following the "root.destroy()" because the root=Tk() is inside theapplication class __init__ definition. So I guess the sequenceCreate application class Create Tk root Run app Destroy Tk rootExit the application classsorta makes sense.On Sat, 31 Mar 2001 21:56:32 GMT, "David Allen" <mda at idatar.com>wrote:>In article <dktbct8ul4jmbnlh4h6acplkauofdh5tup at 4ax.com>, "David Fuess"><fuess at att.net> wrote:>>> I am building Tkinter applications on W2K using ActivePython2.0 and Tcl>> 8.3.2 with Pmw wigets. The problem is that if I try to exit the program>> using a button handler I get an error. I have tried both>> 'sys.exit(0)' and 'root.quit()' in the button handler. In both cases I>> often get the error:>>>> pythonw.exe - Application Error, The instruction at "0x01744727" referenced>> memory at "0x00000000". The memory could not be "read".>>>> This never happens if I close the application using the X in the window>> decorations.>>>> Dave>>Much easier is simply this:>>toplevelwidget.destroy()
More information about the Python-listmailing list
[8]ページ先頭