Jack Cowden wrote:
> I am working with the RTD functions in excel using pythoncom and a
> some great sample code from Chris Nilsson.  In Excel 2003 and 2007, I
> am able to create my python object via the IRTDServer com interface.
> Excel then passes a callback interface, IRTDServerEvents to my
> object.  I hold on to that interface and callback using UpdateNotify
> to let Excel know that I have an update for it.  Everything works fine
> in 2003, but the interface callback in 2007 fails with an obscure COM
> error.(below)   Other than that it works fine 2007.   IMO, if the typelib
> information were wrong, the IRTDServer interface would not work
> either.
> ...
> Exception in thread Thread-471:
> Traceback (most recent call last):
>   File "C:\Python26\Lib\threading.py", line 527, in __bootstrap_inner
>     self.run()
>   File "C:\Python26\Lib\threading.py", line 731, in run
>     self.function(*self.args, **self.kwargs)
>   File "C:\dev\python\ExcelRTD.py", line 391, in Update
>     self.SignalExcel()
>   File "C:\dev\python\ExcelRTD.py", line 151, in SignalExcel
>     raise COMException(desc=str(why))
> COMException: (None, "(-2147352567, 'Exception occurred.', (0, None,
> None, None, 0, 0), None)", None, -1)

For what it's worth, -2147352567 is 0x80020009 which is
DISP_E_EXCEPTION.  That could mean anything from a bad pointer to a math
error to an unhandled C++ exception.

Is your ServerStart returning a value greater than 0?

-- 
Tim Roberts, t...@probo.com
Providenza & Boekelheide, Inc.

_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32

Reply via email to