application object events issue

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I'm developing a VB6 COM Add-In for outlook 2000. I have the following code:

Private WithEvents olApp As Outlook.Application

Private Sub AddinInstance_OnConnection(ByVal Application As Object, ByVal ConnectMode As AddInDesignerObjects.ext_ConnectMode, ByVal AddInInst As Object, custom() As Variant)
Set olApp = Application
.....

When I install and run the add-in, I get the error message:
"Run-time error '459':
Object or class does not support the set of events"

Any help?


thanks,

Selgin
 
Do you have a reference set to Outlook in your project references? Are
you declaring the use of IDTExtensibility2?

Try downloading the ItemsCB COM addin sample from the Resources page
at www.microeye.com. It shows COM addin best practices and you can try
running it to test your own setup.




selgin said:
Hi,

I'm developing a VB6 COM Add-In for outlook 2000. I have the following code:

Private WithEvents olApp As Outlook.Application

Private Sub AddinInstance_OnConnection(ByVal Application As Object,
ByVal ConnectMode As AddInDesignerObjects.ext_ConnectMode, ByVal
AddInInst As Object, custom() As Variant)
 
Back
Top