[Zope-CMF] problem with python script + catalog re: images

Dieter Maurer dieter at handshake.de
Thu Jan 29 14:56:16 EST 2004


Jean-Francois.Doyon at CCRS.NRCan.gc.ca wrote at 2004-1-29 10:40 -0500:
>I'm doing something terribly simple, and it's not working:
>
>for o in context.portal_catalog( meta_type = ['Portal Image'] ):
>    obj = o.getObject()
>    print obj.Title()
>
>return printed
>
>I keep getting told that "NoneType" has no attribute "Title" ...

This means that your catalog has (at least one) entry
that does not longer exist. Use the "Update" button of the
"Catalog" tab on your catalog instance to sanitise your catalog...

-- 
Dieter



More information about the Zope-CMF mailing list