Outlook automation type mismatch (1 Viewer)

pbaldy

Wino Moderator
Staff member
Local time
Yesterday, 23:02
Joined
Aug 30, 2003
Messages
36,125
Wondering if I have a version issue or something. The following snippit from a larger sub works great on my development machine, Access 2k & Office 2k. I get a type mismatch error on the set MyMail line when it runs on a PC with Access 2k Runtime and Outlook 2003.
Code:
  Dim MyOutlook   As Outlook.Application
  Dim MyMail      As Outlook.MailItem

  Set MyOutlook = New Outlook.Application

  'Type mismatch occurs on this line
  Set MyMail = MyOutlook.CreateItem(olMailItem)
Any thoughts would be appreciated.

TIA
 

pbaldy

Wino Moderator
Staff member
Local time
Yesterday, 23:02
Joined
Aug 30, 2003
Messages
36,125
Thanks Travis. That seems to be on point, but I don't see a solution right off. Looks like I have some studying to do.
 

Users who are viewing this thread

Top Bottom