Command Prompt

Terry Reedy tjreedy at udel.edu
Fri May 21 18:11:33 EDT 2004


"EAS" <eriksp at attbi.nospam.com> wrote in message
news:Cnurc.5$hi6.3519 at attbi_s53...
> Is there any way of using Python to open a command prompt?

You may need to be more specific.  On various versions of Windows, in batch
or interactive mode, os.system('command.com') might or might not do what
you want.  On Win XP, interactive mode, one is already in a command window
and the above gives a command prompt 'C:/Python...' in the same window,
where one can do dir, cd, type, etc, and finally exit to return to Python
and its prompt (again in the same window).

Terry J. Reedy







More information about the Python-list mailing list