How to specify both <EventClass> and <Guid> Attributes on a class

M

MikeL

What is the syntax for declaring both <EventClass> and <Guid> attributes on
a class? The following causes an error in the class declaration:

Imports System.Runtime.InteropServices
Imports System.EnterpriseServices

<Guid("0EA77155-29EA-4f1b-870C-B6D7287E65EC")> _
Public Interface IMyEventClass

End Interface

' Below is the problem:

<EventClass()> _
<Guid("E07B09A3-15C6-400a-BD7E-FDAFEF78BC2C")> _
Public Class MyEventClass
Inherits ServicedComponent
Implements IMyEventClass
End Class


Thanks in advance,

Mike
 
M

MikeL

Nevermind, I found the answer:

<EventClass(), _
Guid(".....")> _
Public Class ...

End Class
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top