By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
439,985 Members | 1,574 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 439,985 IT Pros & Developers. It's quick & easy.

Re: call an exturnal program in python

P: n/a
Adam wrote:
I am trying to run an external program in my code using
os.system('exename -exearg') but the exe has an "&" in it so windows
thinks it's two commands any way around this?
Have you tries quoting the exename:

os.system('"exename" -exearg')

That might help. How do you run it from the command line?

You might be better using subprocess.call(), since that allows you to
run subprocesses without the shell interpreting the command line.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC http://www.holdenweb.com/

Nov 21 '08 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.