How to Batch Export Multiple Contacts as Word Documents in Outlook

Outlook doesn’t permit users to export a single contact as a Word document, not to mention exporting multiple contacts as individual Word documents. Therefore, this article will share you a method to achieve that.

Batch Export Multiple Contacts as Word Documents in Outlook

Many users would like to export multiple contacts as separate Word documents in bulk. But, there isn’t a direct feature supporting this. Thus, in the followings, we will introduce a smart way, which is using VBA code. Now, read on to learn the detailed steps and elaborate VBA code.

Batch Export Multiple Contacts as Word Bocuments

  1. For a start, launch your Outlook application.
  2. Then, in the main Outlook window, press “Alt + F11” keys.
  3. Next, you’ll get access to the VBA editor window.
  4. Now, you should firstly enable “Microsoft Word Object Library”, which can be finished by hitting “Tools” > “References”.
  5. Then, you ought to open an unused module.
  6. Subsequently, copy the following VBA code into this module.
Sub BatchExportMultipleContactsIntoWordDocuments()
    Dim objSelectedContacts As Outlook.Selection
    Dim objContact As Outlook.ContactItem
    Dim strLocalFolder As String
    Dim strFileName As String
    Dim objAttachment As Outlook.Attachment
    Dim strPhoto As String
    Dim objWordApp As Word.Application
    Dim objWordDocument As Word.Document
    Dim objWordRange As Word.Range
    Dim objInlineShape As Word.InlineShape
    Set objSelectedContacts = Outlook.Application.ActiveExplorer.Selection
    If Not (objSelectedContacts Is Nothing) Then
       Set objWordApp = CreateObject("Word.Application")
       'Change the path for saving the word documents
       strLocalFolder = "E:\"
       On Error Resume Next
       For Each objContact In objSelectedContacts
           'Export as word document
           strFileName = strLocalFolder & objContact.FullName & ".doc"
           objContact.SaveAs strFileName, olDoc
           'Insert the contact photo to this document
           If objContact.Attachments.count > 0 Then
              For Each objAttachment In objContact.Attachments
                  If InStr(LCase(objAttachment.filename), "contactpicture.jpg") > 0 Then
                     strPhoto = "E:\" & objContact.FullName & ".jpg"
                     objAttachment.SaveAsFile (strPhoto)
                     Set objWordDocument = objWordApp.Documents.Open(strFileName)
                     objWordApp.Visible = True
                     Set objWordRange = objWordDocument.Range(0, 0)
                     objWordRange.InlineShapes.AddPicture filename:=strPhoto, LinkToFile:=False, SaveWithDocument:=True
                     For Each objInlineShape In objWordDocument.InlineShapes
                         objInlineShape.ScaleHeight = 30
                         objInlineShape.ScaleWidth = 30
                     objWordDocument.Close True
                     Kill strPhoto
                  End If
           End If
    End If
End Sub

VBA Code - Batch Export Multiple Contacts as Word Documents

  1. After that, you can exit the current “Microsoft Visual Basic for Applications” window.
  2. Later, for the convenience, you had better go to “Outlook Options” > “Quick Access Toolbar” to add the new macro to Quick Access Toolbar.
  3. Finally, you can take a shot:
  • First off, select multiple contacts which you want to export.
  • Then, hit the macro button in Quick Access Toolbar.
  • After the macro completes, you will get multiple Word documents in the predefined local folder, which are corresponding to the selected contacts.
  • These Word documents will look like the following screenshot:Exported Contacts in Word Documents

What to Do If ScanPST Fails

Outlook comes preinstalled with an inbuilt repair tool – Scanpst. But you cannot pay too much hope to this tool in that it can’t come into effect if the Outlook file is seriously damaged. Therefore, you’re better off keeping a more potent repair tool, such as DataNumen Outlook Repair, in vicinity. It can repair PST file without any fuss.

Author Introduction:

Shirley Zhang is a data recovery expert in DataNumen, Inc., which is the world leader in data recovery technologies, including corrupt sql and outlook repair software products. For more information visit

Comments are closed.