Wensheng wrote:
I just realized I can pass the object itself:
like
p=__import__("printit")
p.pr(self)
Leaving no reason not do do *this* part as
import printit
printit.pr(self)rather than using the internal hook function to do exactly the standard thing.
in printit.py
-------------
def pr(self):
print self.var
-------------------
(Though frankly I don't see the advantage of having this tiny function in a separate file to begin with...)
Jeff Shannon Technician/Programmer Credit International
-- http://mail.python.org/mailman/listinfo/python-list
