0

Is this possible? I yes, can anyone help me how to do it. I don't know how to use subprocess and Popen() to run my sort.bat file.

2
  • 1
    Did you read subprocess's documentation to understand how it works? Commented May 19, 2016 at 10:53
  • @DeepSpace I tried reading it but I'm still confused on how to apply it to run a batch file/process. But it's okay now. I tried the code from Farhan's answer. But if you have a more comprehensive explanation of the subprocess and Popen() codes than the documentation, I would be glad to hear from you. :) Commented May 19, 2016 at 11:08

1 Answer 1

3

You can use os.system:

import os
os.system('Path to your .bat file')
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.