How to Auto Print Tasks or Meetings As They Arrive in Your Outlook Mailbox

Do you often want to print out the tasks assigned by others or the meetings sent by others? Why not configure Outlook to auto print out them? This article will tell you how to achieve it with Outlook VBA.

Outlook allows users to assign tasks and send meeting invitations to others. Have you ever received tasks requests or meeting requests in Outlook? Take me for an example. I often received this kind of requests from my superior. Since that these tasks and meetings are considerably important and urgent, I often print out them in paper. In the past, I normally printed them manually. However, at present, I am using a more intelligent method. That is to enable Outlook to automatically print them as soon as they arrive in my mailbox. Are you interested in this means? If so, you can read on to get the detailed codes as well as operations.

Auto Print Tasks or Meetings As They Arrive in Your Outlook Mailbox

  1. In the first place, you should launch Outlook and head to “Developer” tab.
  2. Then you could locate and click on the “Visual Basic” button.
  3. Next in the popup VBA editor window, double click the “ThisOutlookSession” project on the left side to open it.
  4. In the opened “ThisOutlookSession” project window, you ought to copy and paste the following VBA codes:
Public WithEvents olItems As Outlook.Items

Private Sub Application_Startup()
    Set olItems = Outlook.Application.Session.GetDefaultFolder(olFolderInbox).Items
End Sub

Private Sub olItems_ItemAdd(ByVal Item As Object)
    Dim olTask As TaskItem
    Dim olAppt As AppointmentItem
    Dim olMail As MailItem
    If TypeName(Item) = "TaskRequestItem" Then
       Set olTask = Item.GetAssociatedTask(True)
    End If
    If TypeName(Item) = "MeetingItem" Then
       Set olAppt = Item.GetAssociatedAppointment(True)
    End If
    If TypeName(Item) = "MailItem" Then
       Set olMail = Item
       If InStr(LCase(olMail.Subject), "task") > 0 Or InStr(LCase(olMail.Subject), "meeting") > 0 Then
       End If
    End If
End Sub

VBA Codes - Auto Print Tasks or Meetings As They Arrive in Your Outlook Mailbox

  1. After that, you need to digitally sign the current VBA project.
  • Firstly, you can go to “Start Menu” and type “VBA” in the search box. You’ll find an inbuilt tool. Use it to create a certificate.Digital Certificates for VBA Projects
  • Then back to the “ThisOutlookSession” project and assign the certificate to it.Assign the Digital Certificate to the Current VBA Project
  1. Subsequently, you should proceed to change your Outlook macro settings to only enable digitally signed macros.Change the Macro Settings
  2. Finally, you can restart Outlook to activate the new VBA project. From now on, the meetings and tasks sent by other people will be printed automatically.

Watch out for Malicious Macros

Outlook is susceptible to corruption, especially when faced with malicious macro, namely virus and malware. Once your Outlook data is infected, the inbox repair tool, Scanpst.exe must be of no avail. At that point, your last resort is employing a more powerful Outlook PST data repair tool, such as DataNumen Outlook Repair.

Author Introduction:

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

Comments are closed.