Doug Schwarz wrote: > I don't see how getattr solves the original problem. What, exactly, is > the first argument to getattr?
mod = __import__(__this__) f = getattr(mod,"foo") I tend to prefer this over globals() because it seems a little less magical to me, especially when setting a global. Either this or gloabls() will work fine. Please don't use eval for stuff like this: that's not what it's for and it has the potential to be dangerous. -- CARL BANKS -- http://mail.python.org/mailman/listinfo/python-list