Wednesday, October 7, 2009

Simple calls to Python functions from command line or shortcut « ActiveState Code

CPythonImage via Wikipedia
I had thought that Python was like other scripting/interpreted languages I know like VBA or VBScript, JavaScript, Matlab, or Scheme in that i could just call a function form command line and easily pass arguments  without breaking a sweat of any kind. Turns out that you have to jump through some hoops to run Python. In ArcCatalog, PyDev, or IDLE.there are some nice GUI interfaces that allows you to define inputs and everything and then run your script. Fortunately, I have found a website that gives you code for  easily calling a Python function. I haven't really figured out how to use it butr i want to make a note of it for future use.

Simple calls to Python functions from command line or shortcut « ActiveState Code

Doing this remind me for my Python project I will want to call multiple python scripts from each other. Here is a website where that question is answered:

call one python script from within another





Shared via AddThis


Reblog this post [with Zemanta]

No comments:

Post a Comment