Running python apps from within python apps

aph martin.trojer at gmail.com
Sat Jan 14 10:42:39 EST 2006


actually 'exec()' is the function I was looking for. Working code:

class myApp:

    def kalle(self,str):
        return str.upper()

    def run_script(self,script):
        exec(script)

app = myApp()
app.run_script("print self.kalle('hello')")

Thanks...




More information about the Python-list mailing list