Beginner's question: executing scripts under Win XP pro

J Correia correia_j at KILLTHIShotmail.com
Sat Mar 25 19:21:46 EST 2006


"Scott Souva" <ssouva at spambites.twcny.rr.com> wrote in message 
news:7bna22hp2bj8svrmbof0n6jg6q58oa27i6 at 4ax.com...
> Your script may be working properly, but XP simply removes the window
> after the script runs.  Here is a simple fix that will stop at the end
> of the script and leave the Command window open:
>
> print "Hello World"
> raw_input()

That'll work (it waits for input from the user, and, as soon as it
receives it shuts down the window).

Another way to do it is instead of doubleclicking on the script,
open a command prompt window (Start>Run>cmd OR
Start>Programs>Accessories>Command Prompt) then type
'python test.py' at the prompt.  Now the window stays open
until you specifically close it and you can rerun the script many times.

HTH,

JC 





More information about the Python-list mailing list