Hi Fernando,
generate the definition file for Outlook with the gen_py utility.
After that, try the following code:
import win32com.client
outlookObject = win32com.client.Dispatch("Outlook.View")
then do anything you want on outlookObject. After that release outlookObject
with del outlookObject.
Greets
Florian
"Fernando Gabrieli" <fg*******@extrabold.com> schrieb im Newsbeitrag
news:3b*************************@posting.google.co m...
I need to call Outlook COM methods from Python
Thanks for answering :)
Bye,
Fernando
"Florian Reiser" <fl************@ra-bc.de> wrote in message
news:<bn**********@online.de>...
Hi Fernando,
do you want to call your python class from outlook, or outlook from your
python class?
Greets
Florian
"Fernando Gabrieli" <fg*******@extrabold.com> schrieb im Newsbeitrag
news:3b**************************@posting.google.c om... I need to communicate with Outlook 2000 COM object using win32com in
Python.
I registered a new class and called
win32com.server.register.UseCommandLine(OutlookAdd in)
using this for OutlookAddin
class OutlookAddin:
_com_interfaces_ = ['_IDTExtensibility2']
_public_methods_ = ['alive']
_reg_clsctx_ = pythoncom.CLSCTX_INPROC_SERVER
_reg_clsid_ = "{16925498-0E7D-4d7f-A26B-825D994FBCBC}"
_reg_progid_ = "Test.OutlookAddin"
Also ive defined OnConnection and other events but they NEVER get
called
Somebody knows what is happening ?
Thanks,
Fernando