Python and Lotus Notes

bisj shunjie.bi at gmail.com
Sun Nov 13 07:54:55 EST 2005


I would like to interact with Lotus Notes. I wrote following:
>>> from win32com.client.dynamic import Dispatch
>>> ln=Dispatch('Lotus.Notessession')

then, following exception come out:
Traceback (most recent call last):
  File "<interactive input>", line 1, in ?
  File "C:\Python24\Lib\site-packages\win32com\client\dynamic.py", line
98, in Dispatch
    IDispatch, userName =
_GetGoodDispatchAndUserName(IDispatch,userName,clsctx)
  File "C:\Python24\Lib\site-packages\win32com\client\dynamic.py", line
91, in _GetGoodDispatchAndUserName
    return (_GetGoodDispatch(IDispatch, clsctx), userName)
  File "C:\Python24\Lib\site-packages\win32com\client\dynamic.py", line
79, in _GetGoodDispatch
    IDispatch = pythoncom.CoCreateInstance(IDispatch, None, clsctx,
pythoncom.IID_IDispatch)
com_error: (-2147221005, 'Invalid class string', None, None)

I searched google, above code lines should be ok, but really don't know
how the exception come out. Could this be resolved? Thanks.




More information about the Python-list mailing list