Calling .exe's from module

Oleg Broytmann phd at emerald.netskate.ru
Mon Jun 7 12:10:52 EDT 1999


On Mon, 7 Jun 1999, mike milliger wrote:

> Shouldn't the following module call test.exe? Could someone point me to
> the section in the programming python book which covers this
> functionality?   No objects persist from my executable, so I don't have
> to worry about ref counts and obj's returning to my module. i'm
> basically going to pkzip a list of filenames passed to my module as
> argv's.
> 
> #start
> import string,sys,os
> 
> # --------------------------------------------------------------------
> # run test
> 
> if __name__ == "__main__":
> 
>     os.system ("D:\Archiver\test.exe")

\A is just A, so you run
     os.system ("D:Archivertest.exe")

   Double backslashes:
>     os.system ("D:\\Archiver\\test.exe")

Oleg.
---- 
    Oleg Broytmann  National Research Surgery Centre  http://sun.med.ru/~phd/
           Programmers don't die, they just GOSUB without RETURN.





More information about the Python-list mailing list