Want to catch pywintypes.api_error

Franz GEIGER fgeiger at datec.at
Tue Mar 13 01:47:31 EST 2001


When I start win32api.FindFiles(filespec) with a non-existing filespec it
throws an exception of class pywintypes.api_error. But a "except
pywintypes.api_error, e:" does not work. Using "except Exception, e:" does
the job, because Exception is the base class. But how can I catch api_error?
What do I miss?

Thanks in advance and best regards
Franz GEIGER






More information about the Python-list mailing list