Skip to content

Instantly share code, notes, and snippets.

@pewerner
Created June 13, 2014 11:50
Show Gist options
  • Save pewerner/02496a5f8356c606d83e to your computer and use it in GitHub Desktop.
Save pewerner/02496a5f8356c606d83e to your computer and use it in GitHub Desktop.
Launch a Batch File with IronPYthon
from System.Diagnostics import Process
p = Process()
p.StartInfo.UseShellExecute = False
p.StartInfo.RedirectStandardOutput = False
p.StartInfo.FileName = r"C:\test.bat"
p.Start()
p.WaitForExit()
print(p.ExitCode)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment