使用python运行.exe。等待它完成,然后关闭该ex的命令提示符

2024-10-02 10:27:08 发布

您现在位置:Python中文网/ 问答频道 /正文

如何从python运行.exe,等待该.exe完成执行,然后关闭在.exe开始执行时打开的命令提示符。因此,基本上在最后,我试图关闭的.exe文件,打开之前,但只有在它完成了执行。你知道吗

os.system('C:/mybackup/imageautomation/Etl.PrepareAttachments.exe')                       
'''I want the above exe to run and after completion close itself and 
then run the exe in the below command'''
os.system('C:/mybackup/imageautomation/Etl.UploadAttachments.exe')

Tags: and文件thetorunosetlexe

热门问题