[python-win32] pywintypes.com_error: (-2147467259, 'Unspecified error', None, None)
Blair, Colin S
Colin.Blair at GDIT.com
Fri Apr 22 10:47:46 EDT 2016
Hi Tim,
I have figured out the source of this error. We are running into issues with the comObjectModelGaurd. Our group policy recently changed to disallow programatic access to protected mailItem objects.
Modifying Outlook Users Trust settings or the registry will fix the problem.
R,
C. Blair
________________________________________
From: Blair, Colin S
Sent: Wednesday, March 9, 2016 7:33 AM
To: python-win32 at python.org
Subject: pywintypes.com_error: (-2147467259, 'Unspecified error', None, None)
Thank for the response.
I have tried using the static proxy. The same error occurs.
I have also tried adding DISP_E_EXCEPTION to the ERRORS_BAD_CONTEXT list in dynamic.py
Same result.
R,
Colin B.
Blair, Colin S wrote:
> Please assist me with this error:
>
> Traceback (most recent call last):
>
> print msg.Body
> File "C:\Python27\lib\site-packages\win32com\client\__init__.py", line 466, in
> __getattr__
> return self._ApplyTypes_(*args)
> File "C:\Python27\lib\site-packages\win32com\client\__init__.py", line 459, in
> _ApplyTypes_self._oleobj_.InvokeTypes(dispid, 0, wFlags, retType, argTypes, *args),
> pywintypes.com_error: (-2147467259, 'Unspecified error', None, None)
That's 0x80004005, which for MAPI is MAPI_E_CALL_FAILED. Very generic.
Have you run gentypes.py on Outlook? Perhaps you should try to generate
a static proxy:
ol = win32com.client.gencache.EnsureDispatch("Outlook.Application")
--
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.
More information about the python-win32
mailing list