Computer Learning Zone CLZ Access Excel Word Windows

Curious that we spend more time congratulating people who have succeeded than encouraging people who have not.

-Neil deGrasse Tyson
 
Home   Courses   TechHelp   Help   Contact   Merch   Join   Order   Logon   Forums   
 
Back to Captain's Log    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Classic Outlook Gets Official Death Date
Richard Rost 
          
2 years ago
Classic Outlook gets an official death date as users are urged to switch. Microsoft wants everyone off classic Outlook by April 2026, but will continue to support it until at least 2029.

This will be a problem for developers who rely on using Outlook to send email via VBA. Of course, other methods are available. I personally still use Outlook to receive email into my Access database. Looks like I'll be hunting for a new solution for that.
Alex Hedley  @Reply  
           
2 years ago
Richard Rost OP  @Reply  
          
2 years ago
Microsoft's announcement to sunset classic Outlook by 2026 renders this tutorial idea moot. However, here's the outline I had prepared for teaching people how to push emails into a Microsoft Access database using Outlook, instead of pulling them from Access. Feel free to adapt it for any use before it's no longer applicable.

---

Enable Macros in Outlook

File > Options > Trust Center > Trust Center Settings > Macro Settings  
Enable "All Macros" (only if this is YOUR system and you're confident no one else has access).

---

Turn on the Developer Ribbon

Enable the Developer ribbon in Outlook if it isn't already turned on.

---

Default Inbox Limitation

This process works only for your default inbox. If you use separate PST files, additional steps are required. If there's interest, I could have covered that in a Part 2.  

To locate data files: File > Account Settings > Data Files (PST)

---

Open VBA Editor

1. Open the VB Editor and navigate to the Project Explorer.  
2. Drill down to `ThisOutlookSession`.  

Add the following code in `ThisOutlookSession`:  

1. Application Startup (Test with a Message Box):

CodeDim oNS As Outlook.NameSpace
Dim WithEvents oItems As Outlook.Items

Private Sub Application_Startup()
    Dim oInbox As Outlook.Folder
    Set oNS = Application.GetNamespace("MAPI")
    Set oInbox = oNS.GetDefaultFolder(olFolderInbox)
    Set oItems = oInbox.Items
    Set oInbox = Nothing
End Sub


2. ItemAdd Event (Trigger with a Message Box):

CodePrivate Sub oItems_ItemAdd(ByVal Item As Object)
    ProcessMailItem Item
    Set Item = Nothing
End Sub


Tip: You can trigger this by moving an email from Drafts or Trash into the Inbox.

---

Create a Standard Module

1. Add a reference to the "Microsoft Office 16.0 Access Database Engine Object Library."
2. Add the `ProcessMailItem` subroutine:

CodePublic Sub ProcessMailItem(Item As MailItem)
    Dim db As Database, rs As Recordset
    On Error GoTo EndOfSub

    Set db = OpenDatabase("Z:\OutlookMailTemp.accdb")
    Set rs = db.OpenRecordset("OutlookT")
    rs.AddNew
    rs!FromName = Item.SenderName
    rs!Email = Item.SenderEmailAddress
    rs!Subject = Item.Subject
    rs!Body = Item.Body
    rs!EmailDate = Item.SentOn
    rs!EmailTo = Item.To
    rs.Update
    rs.Close
    db.Close
    Set rs = Nothing
    Set db = Nothing

    Item.Delete

EndOfSub:
    ' Other fields not imported: Item.BodyFormat, Item.Sender, Item.CC, Item.ReceivedTime
    ' Attachments can be extracted - future lesson if demand
End Sub


---

Extracting Attachments

Attachment extraction is possible but was not covered here.

---

Integrate with Access

In your Access database:  

1. Link to `Z:\OutlookMailTemp.accdb`.  
2. Replace any existing "pull from Outlook" routines with a simple append query to move records from `OutlookMailTemp.accdb` into your local table.  

---

If Microsoft's decision hadn't killed this workflow, there could have been more advanced lessons, like handling attachments or working with non-default inboxes. Feel free to reuse any of this for your own projects before Outlook is replaced entirely.
Alex Hedley  @Reply  
           
2 years ago
Worth writing it as its own blog post?
Could be a Code Vault item? A Glossary page or is the Written Articles still hanging about?
Matt Hall  @Reply  
          
2 years ago
There is still 2-5 years of potential use for it, assuming Microsoft doesn't change course along the way.  I wouldn't be uncomfortable creating the tutorial with a disclaimer at the beginning.  Like you, most of us are still using Outlook right now.  Besides, the hard part is done. :)
Richard Rost OP  @Reply  
          
2 years ago
Yeah... Maybe. I put this together because I was sick of getting the occasional security popup from Outlook when Access tries to read email. Even though I've done everything possible to disable it, it still shows up once in a while (usually when I'm on vacation and have to remote into my PC to fix it). Pushing the email from Outlook to Access eliminates that. Maybe I'll make a TechHelp on it.
Thomas Gonder  @Reply  
      
2 years ago
I've been using, what I think is Classic Outlook for over 25 years (I estimate). About a year ago a popup encouraged me to try the new Outlook. It made such a mess of my data I had to do a restore.
Has anyone had recent experience changing to the new Outlook with success?
Does this mean code for the Classic version won't work with the newer version?
Not being up on all things Office, I'm curious as to what older features are missing in the new version, and how important they are to our work in Access. And curious how Microsoft can announce Classic death with features still missing in the newer one?

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Captain's Log.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 8/8/2026 1:17:45 AM. PLT: 1s