Hello - First of all, apologize if I have created this ticket in the wrong place. I tried to look around to find the right place for this issue, and this place seems best fit. Let me know otherwise, and I will move it to the right place.
I am having an issue using this Python for Windows Extensions. I use this to connect to Microsoft Outlook to pull some email messages. Below is the partial code:
import win32com.client
outlook = win32com.client.Dispatch("Outlook.Application")
mapi = outlook.GetNamespace("MAPI")
folders = mapi.GetDefaultFolder(6).Folders
print folders
I would get the following when I execute the script:
<COMObject <unknown="">>
Now, on a different computer, I don't have this issue. I believed I have done the correct installation of Python and this extension. Please help. Thanks!
This tracker isn't for general support - you might like to resend your question to the python-win32 mailing list. You need to be subscribed to the list before you can post to it - see http://mail.python.org/mailman/listinfo/python-win32 for subscription options.
However, it looks like your problem might be that "makepy" hasn't been run on Outlook - the simplest way to do that is to use win32com.client.EnsureDispatch instead of win32com.client.Dispatch.
This fixes the issue. Thank you so much.