Consulting

Results 1 to 3 of 3

Thread: Export whole Outlook email to excel

  1. #1

    Export whole Outlook email to excel

    hi all,

    I am working on export some emails from outlook to excel. Somehow the email body export to excel is one cell and I cannot use the split function to separate those text to column (since after export, spaces between text are gone, and all the text was combined.and lose the format of table.). I also tried using the HTML table nature but somehow it is classified as one cell..


    Is there a way to simulate the manual action like opening the excel and highlight all context in body, and paste it to excel? I manually do this and all the format is good.

    Appreciated.

  2. #2
    Maybe something lke

    Dim olMsg As Outlook.MailItem
    Dim olInsp As Outlook.Inspector
    Dim wdDoc As Object
    Dim oRng As Object
        Set olMsg = ActiveExplorer.Selection.item(1)
        With olMsg
            Set olInsp = .GetInspector
            Set wdDoc = olInsp.WordEditor
            Set oRng = wdDoc.Range
            .Display
            oRng.Copy
        End With
    Graham Mayor - MS MVP (Word) 2002-2019
    Visit my web site for more programming tips and ready made processes
    http://www.gmayor.com

  3. #3
    thx! it works perfectly

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •