Reference to Outlook

  • Thread starter Thread starter Rick
  • Start date Start date
R

Rick

I use code that includes the following to send email from
my database. My computer with everything reinstalled and
now this brings up Outlook Express instead out Outlook.
What do I need to adjust?

Dim objOutlook As Outlook.Application
Dim objOutlookMsg As Outlook.MailItem

' Create the Outlook session.
Set objOutlook = CreateObject("Outlook.Application")
' Create the message.
Set objOutlookMsg = objOutlook.CreateItem(olMailItem)

Thanks.

Rick
 
Make sure that Outlook (not outlook express) is your default app for mail...
Alternatively, you could try;

Set objOutlook = CreateObject("Outlook.Application.9")
 
Back
Top