title: Python Win32 can't read outlook email body's
body: <p>Im trying to use win32 module for python and get the body of my email message. However whenever I try to get it i get an error for any email body I try to get. I am able to get the message subject/timerecieved/etc however I just can't seem to get the body.</p>
  
  <pre><code>import win32com.client
  outlook = win32com.client.Dispatch("Outlook.Application").GetNamespace("MAPI")
  inbox = outlook.GetDefaultFolder(6)
  messages = inbox.Items
  message = messages.GetLast()
  body_content = message.body
  
  ---------------------------------------------------------------------------
  com_error                                 Traceback (most recent call last)
  &lt;ipython-input-41-bdd6c5734297&gt; in &lt;module&gt;()
        1 messages = inbox.Items
        2 message = messages.GetLast()
  ----&gt; 3 body_content = message.body#.encode('ascii', 'ignore').decode('ascii')
        4 #print (body_content)
  
  C:\Users\e659383\Documents\portableapps\WinPython-64bit-3.4.3.5\python-3.4.3.amd64\lib\site-packages\win32com\client\dynamic.py in __getattr__(self, attr)
      509                         debug_attr_print("Getting property Id 0x%x from OLE object" % retEntry.dispid)
      510                         try:
  --&gt; 511                                 ret = self._oleobj_.Invoke(retEntry.dispid,0,invoke_type,1)
      512                         except pythoncom.com_error as details:
      513                                 if details.hresult in ERRORS_BAD_CONTEXT:
  
  com_error: (-2147467259, 'Unspecified error', None, None)
  </code></pre>
  
  <p>I get same error for any email message I try to get the body.</p>