2 Methods to Batch Change the Styles of All Tables in an Outlook Email

Some users would like to change the styles of all tables in an Outlook email in bulk, rather than selecting tables and changing styles one by one. Now, in this article, we will introduce 2 means to you.

At times, you copied some tables to an email from other sources. If you dislike the original styles of these tables, you may want to change them. You may be used to modifying them one by one. However, it is too troublesome if there are numerous tables in this email. Thereby, here we will share you 2 methods to accomplish this in one go.

2 Methods to Batch Change the Styles of All Tables in an Outlook Email

Method 1: Batch Change the Styles of All Tables Manually

  1. First off, open the source email.
  2. If the email is not the one that you are composing, you should turn into the “Edit Mode” firstly. Click “Actions” > “Edit Message”.
  3. Then, you should keep holding down “Ctrl” button and select the tables in the email one by one.Select All Tables
  4. After that, you can switch to “Design” tab under “Table Tools” ribbon.
  5. Next, in the “Table Styles” group, you should select a target table style as per your needs.Select a Target Table Style
  6. At once, the styles of all the tables are changed, like the following screenshot:Changed Table Styles

If there are few tables in this email, this method is still simple and convenient. Yet, if the email contains a great amount of tables, such as 20 or more, selecting them one by one is too tedious. In that case, you apply the VBA code to accomplish it in batches.

Method 2: Batch Change the Styles of All Tables via Outlook VBA

  1. In the first place, access VBA editor according to “How to Run VBA Code in Your Outlook”.
  2. next, enable “MS Word Object Library” with reference to “How to Add an Object Library Reference in VBA“.
  3. Then, put the following VBA code into a module.
Sub BatchChangeStylesOfAllTables ()
    Dim objMail As Outlook.MailItem
    Dim objMailDocument As Word.Document
    Dim objTables As Word.Tables
    Dim objTable As Word.Table
 
    'Get the currently opened email
    Set objMail = Outlook.Application.ActiveInspector.CurrentItem
    Set objMailDocument = objMail.GetInspector.WordEditor
 
    'Get all the tables of the current email
    Set objTables = objMailDocument.Tables
 
    'Convert all tables to text
    For Each objTable In objTables
        'Specify the name of the table style
        objTable.Style = "Light Shading - Accent 3"
    Next
End Sub

VBA Code - Batch Change the Styles of All Tables

  1. After that, add the macro to Quick Access Toolbar.
  2. Finally, all the tables’ styles will be changed to the predefined style.All Table Gets Changed via Macro

Equip Your Outlook with a Formidable Repair Tool

Although Outlook comes pre-installed with a built-in repair tool – Scanpst, you’d better not rely on it completely. It is because that this internal utility is only able to deal with small glitches. It’ll definitely fail in coping with severe situations. So, it is essential for us to keep another PST repair utility in vicinity, like DataNumen Outlook Repair. It can fix Outlook issues without breaking a sweat.

Author Introduction:

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

Leave a Reply

Your email address will not be published. Required fields are marked *