On 3/06/2011 8:55 PM, Umesh Sharma wrote:
hi,
i am working on outlook automation , in my code i am using
dispatchwithevents method for capturing events of outlook as newmail
,itemsend .The code works fine in command line but after converting it
into exe file using py2exe ,the generated exe file crashes .
What do you mean by "crashes"?
I am not using dispatch for generating object of outlook because i have
to do event handling.
here is my code
/////
import time, win32event, win32com.client, pythoncom
class xlEv:
def OnNewMailEx(self,entry):
print 'event happened'
xl=win32com.client.DispatchWithEvents("Outlook.Application", xlEv)
i = input #waiting till event captured
Didn't we already exchange email about this? You probably can't use
input here - you want pythoncom.PumpMessages...
Mark
_______________________________________________
python-win32 mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-win32