Reputation: 590
I want to open an excel file in Microsoft excel, and I don't want to do it using a mouse click but rather a python code. How can I do it?
Upvotes: 0
Views: 79
Reputation: 6748
You can use os.startfile
import os, subprocess
os.startfile(r'filepath') #For windows only
subprocess.call(['open', 'filepath']) #For MAC only
Upvotes: 2