When Outlook is present we can use the following code to work with Outlook.
Dim olNs As NameSpace
Dim olApp as Outlook.Application
Dim olMi As Outlook.MailItem
Dim olAtt As Outlook.Attachment
Dim Fldr As MAPIFolder
Set olapp = CreateObject("Outlook.Application")
Set olNs = olApp.GetNamespace("MAPI")
Set Fldr = olNs;getDefaultFolder(olFolderInbox)
Set olMi = appOutlook.CreateItem(olMailItem)
...
But what if not Outlook but Outlook Express is present.
How can it be done to send a message via Outlook Express from Ms Access?
Dim olNs As NameSpace
Dim olApp as Outlook.Application
Dim olMi As Outlook.MailItem
Dim olAtt As Outlook.Attachment
Dim Fldr As MAPIFolder
Set olapp = CreateObject("Outlook.Application")
Set olNs = olApp.GetNamespace("MAPI")
Set Fldr = olNs;getDefaultFolder(olFolderInbox)
Set olMi = appOutlook.CreateItem(olMailItem)
...
But what if not Outlook but Outlook Express is present.
How can it be done to send a message via Outlook Express from Ms Access?