Rene Pijlman wrote: > Hmm... my spam is a package and eggs is a module. This code gives me: > > AttributeError: 'spam' module has no attribute 'eggs' > > But it works like this: > > spam = __import__('spam',globals(),locals(),['eggs']) > eggs = spam.eggs or: spam = __import__('spam.eggs') eggs = spam.eggs </F>