How to call a system command with flexibility on Windows
peter at engcorp.com
Mon Jan 12 22:32:22 CET 2004
Nicolas Fleury wrote:
> I have a hard time trying to call a system command with the following
> capability on Windows:
> - Redirection of stdout and stderr.
> - Have the return code.
> The documentation seems to say it's only possible on Unix, have I missed
> something. Thx for your help.
It can be done on Windows, although at the very least you cannot redirect
stderr properly from the command line on Win98.... not sure about other
I'm pretty sure return codes are available with os.system() under Windows,
but I rarely use them and forget any relevant details.
More information about the Python-list