Call a Python file with parameters

Irmen de Jong irmen at -NOSPAM-REMOVETHIS-xs4all.nl
Mon Jun 9 22:30:07 CEST 2003


Jp Calderone wrote:
> On Mon, Jun 09, 2003 at 03:10:27PM +0000, martin z wrote:
> 
>>Basically,
>>I want to have a Python file that, when I compile it, I get nothing but a
>>function, or something I can use like a function, that I can shove a
>>parameter tuple into.  Instead I get a code object (no argument tuple) or a
>>module (containing functions).

What's wrong with :

from myModule import myFunction		# or even * if you're bold

myFunction("blahblah",42)


??

--Irmen





More information about the Python-list mailing list