Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Running scripts in IDLE shell?

Status
Not open for further replies.

wowtip

Programmer
Sep 17, 2004
1
0
0
SE
Hi!

Does anyone know of a way of externally running a python script on the fly in the IDLE "Python shell", when running windows? I am asking, because I would prefer to use an external editor for editing scripts, but because of unicode problems with running scripts in command line Python, I would like them to be executed in the IDLE shell.

What I am looking for is something like D:\Python\pythonw.exe script.py[/color blue].

Problem is, the startup command for IDLE in this case would be: D:\Python\pythonw.exe D:\Python\Lib\idlelib\idle.pyw[/color blue].

I tried using:

D:\Python\pythonw.exe D:\Python\Lib\idlelib\idle.pyw D:\Python\script.py[/color blue] which works in a way, it runs the Shell, but place the script in the "Edit script windows" without running it. My prefered behaviour would be if I could use the IDLE shell just like the default python.exe: D:\Python\python.exe script.py [/color blue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top