[python-win32] how to create a valid Sink
Christian K.
ckkart at hoc.net
Thu May 10 01:54:30 CEST 2007
Mark Hammond wrote:
>> I'd like to ask for help on how to create a valid event Sink
>> which I can
>> pass to the Advise() method of a message stores table.
>
> This might be tricky unless pywin32 already has support for the specific
> interface you need.
I want to receive 'new mail' notifications from Outlook.
>> Any class I made up so far gives the same error:
>>
>> File "<stdin>", line 333, in notify
>> TypeError: The Python instance can not be converted to a COM object
>>
>> So what attributes does an object need to be convertable to a
>> COM object?
>
> It would need to be like any other pywin32 COM object; you should be able to
> find info about that on the web.
Forgive my ignorance but those are my first steps with com. Does that
mean I should create and register a COM server?
Basically I'm trying to reimplement the following code in python:
http://www.codeproject.com/internet/CMapiEx.asp
Up to now this was straightforward, but at this point I'm stuck.
Thanks for any help, Christian
More information about the Python-win32
mailing list