COM Addin problem from outside of Outlook!

  • Thread starter Thread starter Darren W.
  • Start date Start date
D

Darren W.

When I run the following code from Outlook, it runs properly doing what it
is suppose to

but when I try to run this code from outside of outlook [either from Visual
Basic or PowerBuilder], the application crashes.

Application.COMAddIns(1).Connect

does anybody have any idea what am I missing?

Thanks in advance
 
Application only applies to Outlook if you are running in Outlook VBA or in
an Outlook COM addin, otherwise use Set objOL =
CreateObject("Outlook.Application").

A specific addin may or may not be COMAddIns(1), it might be some other
index number. Use ComAddins(":myAddinName.Connect") instead and adjust for
your COM addin name.
 
Back
Top