Really dumb question!

Manuel M. Garcia mail at manuelmgarcia.com
Wed Feb 26 01:04:36 EST 2003


On 25 Feb 2003 14:37:58 -0800, snarflemike at yahoo.com (Mike Silva)
wrote:

>So, my son and I are playing around with Python, esp. the turtle
>module, and we can't figure out a way to stop the program!  Ctrl-C (in
>any window) doesn't do it, and closing the Tk graphics window doesn't
>do it (just opens up again and continues drawing).  This gets to be a
>problem when he decides to draw 10 lines and types in 100 by mistake!
>
>So, my really dumb question is -- how do we kill an executing program,
>in particular one doing (turtle) graphics?!
>
>Mike

Are you using Windows?  ActivePython?  I have some versions of Windows
to play with at work.  If you tell me your version of Windows and
Python, I can send you an email to walk you through it.

In general, Python running in Windows is not responsive to Ctrl-C.
The way to stop the program is to close the parent window.  (The
parent window might be Command Prompt, or PythonWin, or its own text
window)  If you run your scripts by double-clicking on an icon, use
the .py extension instead of the .pyw extension, and the parent window
will always be visible.

Manuel




More information about the Python-list mailing list