Answers for "python script to run commands in cmd windows"

5

how to execute a cmd command in python

CMD /K - execute a command then remain

import os
os.system('cmd /k "Your Command Prompt Command"')
Posted by: Guest on July-30-2020
0

how to open cmd and run code using python

os.system("start /wait cmd /c {command}")
Posted by: Guest on December-25-2021

Code answers related to "python script to run commands in cmd windows"

Python Answers by Framework

Browse Popular Code Answers by Language