Re: Can a function be called within a function ?

2005-04-18 Thread Peter Moscatt
Thanks Guys, I didn't think it was calling the function so I will put some test code and print something to the screen just to ensure it's entering the function. Thanks for all ya help. Pete Peter Moscatt wrote: > > Is it possible to write code and allow a function to be called within > an

Re: Can a function be called within a function ?

2005-04-18 Thread Steve Horsley
Peter Moscatt wrote: Is it possible to write code and allow a function to be called within another like I have shown below ? Pete def populatelist(): f=open(_globals.appath + "dxcluster.svr","r") while true: text = f.readline() if text =="":

Re: Can a function be called within a function ?

2005-04-18 Thread Kent Johnson
Peter Moscatt wrote: Is it possible to write code and allow a function to be called within another like I have shown below ? Yes, of course. In fact you do it six times in the code below, to call open(), readline(), append(), close(), main() and populatelist(). Kent Pete def populatelist():

Re: Can a function be called within a function ?

2005-04-18 Thread Tim N. van der Leeuw
Hiya, That's certainly possible, it's standard practice. (It might be cleaner to pass filenames using parameters though) cheers, --Tim -- http://mail.python.org/mailman/listinfo/python-list

Can a function be called within a function ?

2005-04-18 Thread Peter Moscatt
Is it possible to write code and allow a function to be called within another like I have shown below ? Pete def populatelist(): f=open(_globals.appath + "dxcluster.svr","r") while true: text = f.readline() if text =="": b