0

I want to open a program located at a specific path in Python but I am getting this error:

Error

Error in cmd: The system cannot find the file steam.exe

import os
os.system('start steam.exe "D:\Program Files (x86)\Steam"')
Zack Walton
  • 191
  • 1
  • 12

1 Answers1

1

use subprocess:

import subprocess

subprocess.call(['D:\Program Files (x86)\Steam\\steam.exe'])
Zack Walton
  • 191
  • 1
  • 12