Hi, Thanks for the details on hasattr function. I learned a lot ;) In the meantime, I found an other solution. Have a look. Bye, FR. Here I create folders in the folder "self.folder1". Each new folder has a number at its end (folder11, folder12, etc ...). def testFolder(self): self=self.this() sub1=self.folder1 l = ['1','2','3','4'] for i in l: sub2= "self.folder1" + ".folder1" + i folder = "folder1" + i try: if eval(sub2): pass except AttributeError: sub1.manage_addFolder(folder) return 'ok' _______________________________________________ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )