ASPN ActiveState Programmer Network
  ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups | Web Services
SEARCH
advanced | search help

Reference
ActivePython 2.4
Python Documentation
Macintosh Module Reference
1. Using Python on a Macintosh
1.2 The IDE
1.2.1 Using the ``Python Interactive'' window
1.2.2 Writing a Python Script
1.2.3 Executing a script from within the IDE
1.2.4 ``Save as'' versus ``Save as Applet''

MyASPN >> Reference >> ActivePython 2.4 >> Python Documentation >> Macintosh Module Reference >> 1. Using Python on a Macintosh >> 1.2 The IDE
ActivePython 2.4 documentation


1.2.2 Writing a Python Script

In addition to using the Python IDE interactively, you can also type out a complete Python program, saving it incrementally, and execute it or smaller selections of it.

You can create a new script, open a previously saved script, and save your currently open script by selecting the appropriate item in the ``File'' menu. Dropping a Python script onto the Python IDE will open it for editing.

When the Python IDE saves a script, it uses the creator code settings which are available by clicking on the small black triangle on the top right of the document window, and selecting ``save options''. The default is to save the file with the Python IDE as the creator, this means that you can open the file for editing by simply double-clicking on its icon. You might want to change this behaviour so that it will be opened by the PythonLauncher, and run. To do this simply choose ``PythonLauncher'' from the ``save options''. Note that these options are associated with the file not the application.

See About this document... for information on suggesting changes.

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState 2004 All rights reserved