Calling scripts from within scripts, is this possible?

Zac Jensen listbox at cybereal.org
Sun Jun 15 20:26:32 CEST 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sunday 15 June 2003 10:47 am, Gerry Sutton wrote:
>
> 2)      When invoked, the master App. somehow loads and executes another
> script file that can access the Master Apps variables, Objects and make use
> of the modules imported by the Master App. The slave script sees these as
> though they were system or global services. The slave script is simple and
> may or may not import other modules for its own use and may or may not
> define its own classes, variables, etc. Usually this slave script will just
> be a set of procedural commands that make calls to resources defined and
> controlled by the master App.
>
> 3)      When execution reaches the end of the Slave script file the Master
> regains control and another slave script could be called.
>
>
>
> To reiterate, my question revolves around how to do steps 2) and 3)

execfile()

Found in builtins.

I had this same issue myself the first day I used python, being able to do 
this, is why I decided I liked python :) Though there are thousands of 
reasons beyond that now.

- -Zac
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQE+7LpbV3L7YsSif1URAnbZAKCPNnVSnmPHfDbQ2I9nyjMOMS/AwACbBTAV
/DoeraQ4mbuiYAOSRvhN+Xk=
=v7ss
-----END PGP SIGNATURE-----






More information about the Python-list mailing list