-ordi-
Junior Poster in Training
92 posts since Dec 2009
Reputation Points: 18
Solved Threads: 11
Do help(humansize) or dir(humansize) and call the main function of the file. Why can you not open the file normally and run it from editor side by F5. Final testing is better done without IDE from CMD prompt or launch the program by double clicking the file. I currently like to work in ContextEditor where I have defined function keys to launch the program with 2.6, 2.7 and 3.2. Sometimes I am missing the code completion and help features of Idle and run it side by side with the text editor.
You might like to use Ipython for better command line.
pyTony
pyMod
5,359 posts since Apr 2010
Reputation Points: 782
Solved Threads: 852
humansize.py from the >>> prompt in the shell (interactive IDLE). How do I do that?
You dont do that because it wrong.
To run a script.
Fromcmd python humansize.py or as posted by tony by using File->new window then F5(run) .
If you want to use humansize.py in IDLE you have to import it.
How to import and using a script look at this post. http://www.daniweb.com/forums/thread322120.html
A good editor like pyscripter make it easy,it has run button.
http://code.google.com/p/pyscripter/
snippsat
Practically a Posting Shark
808 posts since Aug 2008
Reputation Points: 353
Solved Threads: 294